[Backport][5.15] Support KP950 for velinux-5.15#121
Open
jackYoung0915 wants to merge 196 commits intoopenvelinux:5.15-velinuxfrom
Open
[Backport][5.15] Support KP950 for velinux-5.15#121jackYoung0915 wants to merge 196 commits intoopenvelinux:5.15-velinuxfrom
jackYoung0915 wants to merge 196 commits intoopenvelinux:5.15-velinuxfrom
Conversation
commit 2509969 upstream. We'd like panels to be able to add things to debugfs underneath the connector's directory. Let's plumb it through. A panel will be able to put things in a "panel" directory under the connector's directory. Note that debugfs is not ABI and so it's always possible that the location that the panel gets for its debugfs could change in the future. NOTE: this currently only works if you're using a modern architecture. Specifically the plumbing relies on _both_ drm_bridge_connector and drm_panel_bridge. If you're not using one or both of these things then things won't be plumbed through. As a side effect of this change, drm_bridges can also get callbacks to put stuff underneath the connector's debugfs directory. At the moment all bridges in the chain have their debugfs_init() called with the connector's root directory. Signed-off-by: Douglas Anderson <dianders@chromium.org> Reviewed-by: Javier Martinez Canillas <javierm@redhat.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Link: https://patchwork.freedesktop.org/patch/msgid/20220204161245.v2.2.Ib0bd5346135cbb0b63006b69b61d4c8af6484740@changeid Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 225a8d0 upstream. Implement polling for VGA and SIL164 connectors. Set the flag DRM_CONNECTOR_POLL_DISCONNECT for each to detect the removal of the monitor cable. Implement struct drm_connector_helper_funcs.detect_ctx for each type of connector by testing for EDID data. The helper drm_connector_helper_detect_ctx() implements .detect_ctx() on top of the connector's DDC channel. The function can be used by other drivers as companion to drm_connector_helper_get_modes(). v6: - change helper name to drm_connector_helper_detec_from_ddc() (Maxime, Sui) v5: - share implementation in drm_connector_helper_detect_ctx() (Maxime) - test for DDC presence with drm_probe_ddc() (Maxime, Jani) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Jocelyn Falempe <jfalempe@redhat.com> Acked-by: Sui Jingfeng <sui.jingfeng@linux.dev> Acked-by: Maxime Ripard <mripard@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20240325200855.21150-13-tzimmermann@suse.de Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 057e77972556aed4a0f1eed7eeb85024d0a22ba1 upstream. Add dp aux read/write functions. They are basic functions and will be used later. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Tian Tao <tiantao6@hisilicon.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250103093824.1963816-2-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 54063d86e0369f53f180137e5e889bc19cd9015b upstream. Add link training process functions in this moduel. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Tian Tao <tiantao6@hisilicon.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250103093824.1963816-3-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 94ee73ee30208f3d92b2f2a4f7d3346ba56245bf upstream. Build a dp level that hibmc driver can enable dp by calling their functions. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Tian Tao <tiantao6@hisilicon.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250103093824.1963816-4-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 587013d72c1a217ced9f42a9a08c8013052cabfc upstream. Refactored struct hibmc_drm_private to separate VGA module from generic struct. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Tian Tao <tiantao6@hisilicon.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250103093824.1963816-5-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 0ab6ea261c1fe4edbf4d99dfe65d8ebaae905092 upstream. To support DP interface displaying in hibmc driver. Add a encoder and connector for DP modual. The HPD function and get_edid function will be add in next series, so temporarily using 1024x768 as default in hibmc_dp_connector_get_modes() Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Reviewed-by: Tian Tao <tiantao6@hisilicon.com> Link: https://patchwork.freedesktop.org/patch/msgid/20250103093824.1963816-6-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 2075a73 upstream. Replace module_pci_driver() with drm_module_pci_driver(). The DRM macro respects drm_firmware_drivers_only() and fails if the flag has been set. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Javier Martinez Canillas <javierm@redhat.com> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com> Link: https://patchwork.freedesktop.org/patch/msgid/20211222082831.196562-6-javierm@redhat.com Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 53225f3 upstream. Set the preferred color depth to 24 bits and the fbdev bpp to 32 bits. This will signal XRGB8888 as default format to clients. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Javier Martinez Canillas <javierm@redhat.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: https://patchwork.freedesktop.org/patch/msgid/20221123115348.2521-2-tzimmermann@suse.de Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit f9698f802e50fbe696b3ac6f82c0e966574a3edb upstream. Move the macros below their corresponding registers to make them more obvious. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://lore.kernel.org/r/20250331074212.3370287-2-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
… and pre-emphasis commit 9e736cd444f49efa2334e405f7a59773ea02155b upstream. This dp controller need features of digital-to-analog conversion and high-speed transmission in chip by its extern serdes controller. Our serdes cfg is relatively simple, just need two register configurations. Don't need too much functions, like: power on/off, initialize, and some complex configurations, so I'm not going to use the phy framework. This serdes is inited and configured in dp initialization, and also integrating them into link training process. For rate changing, we can change from 1.62-8.2Gpbs by cfg reg. For voltage and pre-emphasis levels changing, we can cfg different serdes ffe value. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://lore.kernel.org/r/20250331074212.3370287-3-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 5f80fb4d6abd1f7f4007e4bf8dd75a8c71d2f724 upstream. Add dp serdes cfg in link training process, and related adapting and modificating. Change some init values about training, because we want completely to negotiation process, so we start with the maximum rate and the electrical characteristic level is 0. Because serdes default cfgs is changed and used in hibmc_kms_init(), we changed the if-statement to check whether the value is 0. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://lore.kernel.org/r/20250331074212.3370287-4-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 1e7f35512e77dd7276e91ade4e03807f88b97eb3 upstream. Because the drm_aux of struct hibmc_dp_dev's member is not easy to get in hibmc_drm_dp.c, move the drm_aux to struct hibmc_dp. Then there are some adaptations and modifications to make this patch compile. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://lore.kernel.org/r/20250331074212.3370287-5-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
…nnel commit bd1c935811ae6bd112321c50ed83444eca4facc8 upstream. Add registering drm_aux and use it to get connector edid with drm functions. Add ddc channel in connector initialization to put drm_aux in drm_connector. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://lore.kernel.org/r/20250331074212.3370287-6-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 2f6182616cfdb154e2ecfe9554bb814b8a6378e9 upstream. DP controller can support generating a color bar signal over the DisplayPort interface. This can be useful to check for possible DDR or GPU problems, as the signal generator resides completely in the DP block. Add debugfs file that controls colorbar generator. echo: config the color bar register to display cat: print the color bar configuration Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://lore.kernel.org/r/20250331074212.3370287-7-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 3c7623fb5bb6c319531b941b15b7bfc12455d3d3 upstream. Add HPD interrupt enable functions in drm framework, and also add detect_ctx functions. Because of the debouncing when HPD pulled out, add 200 ms delay in detect. Add link reset process to reset link status when a new connector pulgged in. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://lore.kernel.org/r/20250331074212.3370287-8-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit b11bc1ae46587f3563c47078e605184f18e7fa57 upstream. To realize HPD feature, request irq for HPD , add its handler function. We use pci_alloc_irq_vectors() to get our msi irq, because we have two interrupts now. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://lore.kernel.org/r/20250331074212.3370287-9-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 4c962bc929f1734d209a0862359e25fef8f56fa0 upstream. Because the connected VGA connector would make driver can't get the userspace call, adding detect_ctx in vga connector to make HPD active userspace. Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Link: https://lore.kernel.org/r/20250331074212.3370287-10-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: chenyi <chenyi211@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
…failed commit e5f48bfa2ae0806d5f51fb8061afc619a73599a7 upstream. Currently the driver missed to clean the i2c adapter when vdac init failed. It may cause resource leak. Fixes: a0d078d ("drm/hisilicon: Features to support reading resolutions from EDID") Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Link: https://lore.kernel.org/r/20250813094238.3722345-2-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 8bed4ec42a4e0dc8113172696ff076d1eb6d8bcb upstream.
The local variable is passed in request_irq (), and there will be use
after free problem, which will make request_irq failed. Using the global
irq name instead of it to fix.
Fixes: b11bc1ae4658 ("drm/hisilicon/hibmc: Add MSI irq getting and requesting for HPD")
Signed-off-by: Baihan Li <libaihan@huawei.com>
Signed-off-by: Yongbang Shi <shiyongbang@huawei.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250813094238.3722345-4-shiyongbang@huawei.com
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 93a08f856fcc5aaeeecad01f71bef3088588216a upstream. When hibmc loaded failed, the driver use hibmc_unload to free the resource, but the mutexes in mode.config are not init, which will access an NULL pointer. Just change goto statement to return, because hibnc_hw_init() doesn't need to free anything. Fixes: b3df5e6 ("drm/hibmc: Drop drm_vblank_cleanup") Signed-off-by: Baihan Li <libaihan@huawei.com> Signed-off-by: Yongbang Shi <shiyongbang@huawei.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Link: https://lore.kernel.org/r/20250813094238.3722345-5-shiyongbang@huawei.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 9f98b429ba67d430b873e06bcfb90afa22888978 upstream.
In some case, the dp link training success at 8.1Gbps, but the sink's
maximum supported rate is less than 8.1G. So change the default 8.1Gbps
link rate to the rate that reads from devices' capabilities.
Fixes: 54063d86e036 ("drm/hisilicon/hibmc: add dp link moduel in hibmc drivers")
Signed-off-by: Baihan Li <libaihan@huawei.com>
Signed-off-by: Yongbang Shi <shiyongbang@huawei.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250813094238.3722345-6-shiyongbang@huawei.com
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 3271faf42d135bcf569c3ff6af55c21858eec212 upstream.
If VGA and DP connected together, there will be only one can get crtc.
Add encoder possible_clones to support two connectors enable.
Fixes: 3c7623fb5bb6 ("drm/hisilicon/hibmc: Enable this hot plug detect of irq feature")
Signed-off-by: Baihan Li <libaihan@huawei.com>
Signed-off-by: Yongbang Shi <shiyongbang@huawei.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250813094238.3722345-8-shiyongbang@huawei.com
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 9ab127a18018fb06bd42a54ed38bb7b8c449d686 upstream.
Without the DP helper code, the newly added displayport support
causes a link failure:
x86_64-linux-ld: drivers/gpu/drm/hisilicon/hibmc/dp/dp_aux.o: in function `hibmc_dp_aux_init':
dp_aux.c:(.text+0x37e): undefined reference to `drm_dp_aux_init'
x86_64-linux-ld: drivers/gpu/drm/hisilicon/hibmc/dp/dp_link.o: in function `hibmc_dp_link_set_pattern':
dp_link.c:(.text+0xae): undefined reference to `drm_dp_dpcd_write'
x86_64-linux-ld: drivers/gpu/drm/hisilicon/hibmc/dp/dp_link.o: in function `hibmc_dp_link_get_adjust_train':
dp_link.c:(.text+0x121): undefined reference to `drm_dp_get_adjust_request_voltage'
x86_64-linux-ld: dp_link.c:(.text+0x12e): undefined reference to `drm_dp_get_adjust_request_pre_emphasis'
x86_64-linux-ld: drivers/gpu/drm/hisilicon/hibmc/dp/dp_link.o: in function `hibmc_dp_link_training':
dp_link.c:(.text+0x2b0): undefined reference to `drm_dp_dpcd_write'
x86_64-linux-ld: dp_link.c:(.text+0x2e3): undefined reference to `drm_dp_dpcd_write'
Add both DRM_DISPLAY_DP_HELPER and DRM_DISPLAY_HELPER, which is
in turn required by the former.
Fixes: 0ab6ea261c1f ("drm/hisilicon/hibmc: add dp module in hibmc")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20250127071059.617567-1-arnd@kernel.org
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit b77e995 upstream. Currently we don't have any coverage of the syscall ABI so let's add a very dumb test program which sets up register patterns, does a sysscall and then checks that the register state after the syscall matches what we expect. The program is written in an extremely simplistic fashion with the goal of making it easy to verify that it's doing what it thinks it's doing, it is not a model of how one should write actual code. Currently we validate the general purpose, FPSIMD and SVE registers. There are other thing things that could be covered like FPCR and flags registers, these can be covered incrementally - my main focus at the minute is covering the ABI for the SVE registers. The program repeats the tests for all possible SVE vector lengths in case some vector length specific optimisation causes issues, as well as testing FPSIMD only. It tries two syscalls, getpid() and sched_yield(), in an effort to cover both immediate return to userspace and scheduling another task though there are no guarantees which cases will be hit. A new test directory "abi" is added to hold the test, it doesn't seem to fit well into any of the existing directories. Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20211210184133.320748-7-broonie@kernel.org Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Qi Xi <xiqi2@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 7a9bcaa upstream. Add some trivial hwcap validation which checks that /proc/cpuinfo and AT_HWCAP agree with each other and can verify that for extensions that can generate a SIGILL due to adding new instructions one appears or doesn't appear as expected. I've added SVE and SME, other capabilities can be added later if this gets merged. This isn't super exciting but on the other hand took very little time to write and should be handy when verifying that you wired up AT_HWCAP properly. Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20220829154602.827275-1-broonie@kernel.org Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Qi Xi <xiqi2@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit d70175b upstream. Add a test for the newly added HWCAP2_HBC. Signed-off-by: Joey Gouly <joey.gouly@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will@kernel.org> Link: https://lore.kernel.org/r/20230804143746.3900803-3-joey.gouly@arm.com Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: Qi Xi <xiqi2@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 3a46b35 upstream. The Arm v8.8 extension adds a new control FEAT_TIDCP1 that allows the kernel to disable all implementation-defined system registers and instructions in userspace. This can improve robustness against covert channels between processes, for example in cases where the firmware or hardware didn't disable that functionality by default. The kernel does not currently support any implementation-defined features, as there are no hwcaps for any such features, so disable all imp-def features unconditionally. Any use of imp-def instructions will result in a SIGILL being delivered to the process (same as for undefined instructions). Signed-off-by: Kristina Martsenko <kristina.martsenko@arm.com> Link: https://lore.kernel.org/r/20220622115424.683520-1-kristina.martsenko@arm.com Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: Qi Xi <xiqi2@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 7f86d12 upstream. Add a HWCAP for FEAT_HBC, so that userspace can make a decision on using this feature. Signed-off-by: Joey Gouly <joey.gouly@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will@kernel.org> Link: https://lore.kernel.org/r/20230804143746.3900803-2-joey.gouly@arm.com Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: Qi Xi <xiqi2@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit b206a70 upstream. In order to allow us to have shared code for managing fine grained traps for KVM guests add it as a detected feature rather than relying on it being a dependency of other features. Acked-by: Catalin Marinas <catalin.marinas@arm.com> Reviewed-by: Eric Auger <eric.auger@redhat.com> Signed-off-by: Mark Brown <broonie@kernel.org> [maz: converted to ARM64_CPUID_FIELDS()] Link: https://lore.kernel.org/r/20230301-kvm-arm64-fgt-v4-1-1bf8d235ac1f@kernel.org Reviewed-by: Zenghui Yu <yuzenghui@huawei.com> Reviewed-by: Miguel Luis <miguel.luis@oracle.com> Reviewed-by: Jing Zhang <jingzhangos@google.com> Signed-off-by: Marc Zyngier <maz@kernel.org> Link: https://lore.kernel.org/r/20230815183903.2735724-10-maz@kernel.org Signed-off-by: Qi Xi <xiqi2@huawei.com> Signed-off-by: yeyiyang <yeyiyang3@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 0960e535be5403954701b06e722b68b53463cbe0 upstream. Version 1 and 2 of L3C PMU also use different HID. Make use of struct acpi_device_id::driver_data for version specific information rather than judge the version register. This will help to simplify the probe process and also a bit easier for extension. Acked-by: Jonathan Cameron <jonathan.cameron@huawei.com> Signed-off-by: Yicong Yang <yangyicong@hisilicon.com> Signed-off-by: Yushan Wang <wangyushan12@huawei.com> Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com> Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 2271f1634243897cf18763386994d613a0594d98 upstream. L3C PMU has 4 filter options which are sharing perf_event_attr::config1. Driver will check config1 to see whether a certain event has a filter setting. It'll be incorrect if we make use of other bits in config1 for non-filter options. So check whether each filter options are set directly in a separate function instead. Acked-by: Jonathan Cameron <jonathan.cameron@huawei.com> Signed-off-by: Yicong Yang <yangyicong@hisilicon.com> Signed-off-by: Yushan Wang <wangyushan12@huawei.com> Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com> Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit ede339ff61c61a1ac3bedd01528e4d701d4aea22 upstream. Currently the tt_core's using config1's bit [7, 0] and can not be extended. For some platforms there's more the 8 CPUs sharing the L3 cache. So make tt_core use config2's bit [15, 0] and the remaining bits in config2 is reserved for extension. Acked-by: Jonathan Cameron <jonathan.cameron@huawei.com> Signed-off-by: Yicong Yang <yangyicong@hisilicon.com> Signed-off-by: Yushan Wang <wangyushan12@huawei.com> Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com> Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit b3abb08d6f628a76c36bf7da9508e1a67bf186a0 upstream. The event register is configured using hisi_pmu::base directly since only one address space is supported for L3C PMU. We need to extend if events configuration locates in different address space. In order to make preparation for such hardware, extract the event register configuration to separate function using hw_perf_event::event_base as each event's base address. Implement a private hisi_uncore_ops::get_event_idx() callback for initialize the event_base besides get the hardware index. No functional changes intended. Acked-by: Jonathan Cameron <jonathan.cameron@huawei.com> Signed-off-by: Yicong Yang <yangyicong@hisilicon.com> Signed-off-by: Yushan Wang <wangyushan12@huawei.com> Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 475d94dfe7c635b4311b6c9d87f49534eab6589c upstream. This patch adds support for L3C PMU v3. The v3 L3C PMU supports an extended events space which can be controlled in up to 2 extra address spaces with separate overflow interrupts. The layout of the control/event registers are kept the same. The extended events with original ones together cover the monitoring job of all transactions on L3C. The extended events is specified with `ext=[1|2]` option for the driver to distinguish, like below: perf stat -e hisi_sccl0_l3c0_0/event=<event_id>,ext=1/ Currently only event option using config bit [7, 0]. There's still plenty unused space. Make ext using config [16, 17] and reserve bit [15, 8] for event option for future extension. With the capability of extra counters, number of counters for HiSilicon uncore PMU could reach up to 24, the usedmap is extended accordingly. The hw_perf_event::event_base is initialized to the base MMIO address of the event and will be used for later control, overflow handling and counts readout. We still make use of the Uncore PMU framework for handling the events and interrupt migration on CPU hotplug. The framework's cpuhp callback will handle the event migration and interrupt migration of orginial event, if PMU supports extended events then the interrupt of extended events is migrated to the same CPU choosed by the framework. A new HID of HISI0215 is used for this version of L3C PMU. Acked-by: Jonathan Cameron <jonathan.cameron@huawei.com> Signed-off-by: Yicong Yang <yangyicong@hisilicon.com> Co-developed-by: Yushan Wang <wangyushan12@huawei.com> Signed-off-by: Yushan Wang <wangyushan12@huawei.com> Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit f8f89e8cf3d668a40106444276d8c448c114e963 upstream. PMCCNTR_EL0 is preferred for counting CPU_CYCLES under certain conditions. Factor out the condition check to a separate function for further extension. Add documents for better understanding. No functional changes intended. Reviewed-by: James Clark <james.clark@linaro.org> Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Yicong Yang <yangyicong@hisilicon.com> Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit c3d78c34ad009a7cce57ae5b5c93e1bd03bb31a3 upstream.
CPU_CYCLES is expected to count the logical CPU (PE) clock. Currently it's
preferred to use PMCCNTR_EL0 for counting CPU_CYCLES, but it'll count
processor clock rather than the PE clock (ARM DDI0487 L.b D13.1.3) if
one of the SMT siblings is not idle on a multi-threaded implementation.
So don't use it on SMT cores.
Introduce topology_core_has_smt() for knowing the SMT implementation and
cached it in arm_pmu::has_smt during allocation.
When counting cycles on SMT CPU 2-3 and CPU 3 is idle, without this
patch we'll get:
[root@client1 tmp]# perf stat -e cycles -A -C 2-3 -- stress-ng -c 1
--taskset 2 --timeout 1
[...]
Performance counter stats for 'CPU(s) 2-3':
CPU2 2880457316 cycles
CPU3 2880459810 cycles
1.254688470 seconds time elapsed
With this patch the idle state of CPU3 is observed as expected:
[root@client1 ~]# perf stat -e cycles -A -C 2-3 -- stress-ng -c 1
--taskset 2 --timeout 1
[...]
Performance counter stats for 'CPU(s) 2-3':
CPU2 2558580492 cycles
CPU3 305749 cycles
1.113626410 seconds time elapsed
Signed-off-by: Yicong Yang <yangyicong@hisilicon.com>
Signed-off-by: Will Deacon <will@kernel.org>
Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 99ece71 upstream. Modify the ACPI code to use acpi_fetch_acpi_dev() instead of acpi_bus_get_device() where applicable. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Reviewed-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 52ce504 upstream. The usage of white space in the ACPI thermal driver is not very consistent, so improve that a bit. While at it, add missing braces to if()/else in a few places. No functional impact. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 9e8bc16 upstream. Some expressions in the ACPI thermal driver contain redundant parentheses. Drop them. No functional impact. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 36f5540 upstream. Drop some redundant initialization of local variables, a redundant return statement and a redundant "else" from the ACPI thermal driver. No functional impact. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 6c0eb5b upstream. For bus-based driver, device removal is implemented as: 1 device_remove()-> 2 bus->remove()-> 3 driver->remove() Driver core needs no inform from callee(bus driver) about the result of remove callback. In that case, commit fc7a620 ("bus: Make remove callback return void") forces bus_type::remove be void-returned. Now we have the situation that both 1 & 2 of calling chain are void-returned, so it does not make much sense for 3(driver->remove) to return non-void to its caller. So the basic idea behind this change is making remove() callback of any bus-based driver to be void-returned. This change, for itself, is for device drivers based on acpi-bus. Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: Lee Jones <lee@kernel.org> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Dawei Li <set_pte_at@outlook.com> Reviewed-by: Maximilian Luz <luzmaximilian@gmail.com> # for drivers/platform/surface/* Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 5733622 upstream. It is not necessary to compare critical.flags.valid to 1 in acpi_thermal_trips_update() and doing so is also inconsistent with other similar checks in that code, so simply check if the flag is not 0 instead. No expected functional impact. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 7cefbaf upstream. There are still some drivers needing to play with the thermal zone device internals. That is not the best but until we can figure out if the information is really needed, let's encapsulate the field used in the thermal zone device structure, so we can move forward relocating the thermal zone device structure definition in the thermal framework private headers. Some drivers are accessing tz->device, that implies they need to have the knowledge of the thermal_zone_device structure but we want to self-encapsulate this structure and reduce the scope of the structure to the thermal core only. By adding this wrapper, these drivers won't need the thermal zone device structure definition and are no longer an obstacle to its relocation to the private thermal core headers. Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 66d39e7 upstream. In order to get the device associated with the thermal zone, let's use the wrapper thermal_zone_device() instead of accessing directly the content of the thermal zone device structure. Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> [ rjw: Subject adjustment, removal of trailing white space ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit a4b8171 upstream. The ACPI thermal driver creates extra sysfs attributes in its own directory pointing to the thermal zone it is related to and add a pointer to the sysfs ACPI thermal device from the thermal zone sysfs entry. This is very specific to this ACPI thermal driver, let's encapsulate the related creation/deletion code to group it inside a function we can identify later for removal if needed. Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> [ rjw: Subject adjustment, removal of trailing white space ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 54f9927 upstream. Time to remove this test trb in td math check that was added in early stage of xhci driver development. It verified that the size, alignment and boundaries of the event and command rings allocated by the driver itself are correct. Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Link: https://lore.kernel.org/r/20230202150505.618915-3-mathias.nyman@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit b17a57f upstream. xHC supports several interrupters, each with its own mmio register set, event ring and MSI/MSI-X vector. Transfers can be assigned different interrupters when queued. See xhci 4.17 for details. Current driver only supports one interrupter. Create a xhci_interrupter structure containing an event ring, pointer to mmio registers for this interrupter, variables to store registers over s3 suspend, erst, etc. Add functions to create and free an interrupter, and pass an interrupter pointer to functions that deal with events. Secondary interrupters are also useful without having an interrupt vector. One use case is the xHCI audio sideband offloading where a DSP can take care of specific audio endpoints. When all transfer events of an offloaded endpoint can be mapped to a separate interrupter event ring the DSP can poll this ring, and we can mask these events preventing waking up the CPU. Only minor functional changes such as clearing some of the interrupter registers when freeing the interrupter. Still create only one primary interrupter. Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Link: https://lore.kernel.org/r/20230202150505.618915-4-mathias.nyman@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 52dd048 upstream. Simple helpers to set and clear the IE (interrupter enable) bit for an interrupter. Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Link: https://lore.kernel.org/r/20230202150505.618915-5-mathias.nyman@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit bea5892d0ed274e03655223d1977cf59f9aff2f2 upstream. Current xhci bus resume implementation prevents xHC host from generating interrupts during high-speed USB 2 and super-speed USB 3 bus resume. Only reason to disable interrupts during bus resume would be to prevent the interrupt handler from interfering with the resume process of USB 2 ports. Host initiated resume of USB 2 ports is done in two stages. The xhci driver first transitions the port from 'U3' to 'Resume' state, then wait in Resume for 20ms, and finally moves port to U0 state. xhci driver can't prevent interrupts by keeping the xhci spinlock due to this 20ms sleep. Limit interrupt disabling to the USB 2 port resume case only. resuming USB 2 ports in bus resume is only done in special cases where USB 2 ports had to be forced to suspend during bus suspend. The current way of preventing interrupts by clearing the 'Interrupt Enable' (INTE) bit in USBCMD register won't prevent the Interrupter registers 'Interrupt Pending' (IP), 'Event Handler Busy' (EHB) and USBSTS register Event Interrupt (EINT) bits from being set. New interrupts can't be issued before those bits are properly clered. Disable interrupts by clearing the interrupter register 'Interrupt Enable' (IE) bit instead. This way IP, EHB and INTE won't be set before IE is enabled again and a new interrupt is triggered. Reported-by: Devyn Liu <liudingyuan@huawei.com> Closes: https://lore.kernel.org/linux-usb/b1a9e2d51b4d4ff7a304f77c5be8164e@huawei.com/ Cc: stable@vger.kernel.org Tested-by: Devyn Liu <liudingyuan@huawei.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Link: https://lore.kernel.org/r/20250410151828.2868740-6-mathias.nyman@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
…ugfs commit 7430764 upstream. Due to the reading of FIFO during the dump of data registers in debugfs, if SPI transmission is in progress, it will be affected and may result in transmission failure. Therefore, the dump interface of data registers in debugfs is removed. Fixes: 2b2142f ("spi: hisi-kunpeng: Add debugfs support") Signed-off-by: Devyn Liu <liudingyuan@huawei.com> Reviewed-by: Jay Fang <f.fangjian@huawei.com> Signed-off-by: Junhua Lu <lujunhua7@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit c3c4f22 upstream. We get the configuration of max_frequency from the firmware, which is used to calculate the clk_div together with the set speed. If the speed set by the user is too small, it may cause the clk_div to be too large to exceed the variable range. Therefore, we limit the minimum value of the speed configuration to the value obtained by (master->max_speed_hz/CLK_DIV_MAX). Signed-off-by: Devyn Liu <liudingyuan@huawei.com> Signed-off-by: Junhua Lu <lujunhua7@h-partners.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit a164ff5 upstream. We have a couple of users of this helper, make it available for them. The prototype for the helper is specifically crafted in order to be easily used with bus_find_device() call. That's why its location is in the driver core rather than ACPI. Reviewed-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20211014134756.39092-1-andriy.shevchenko@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
…de match commit adbc49a upstream. Previous patch modified the standard used by acpi_gpiochip_find() to match device nodes. Using the device node set in gc->gpiodev->d- ev instead of gc->parent. However, there is a situation in gpio-dwapb where the GPIO device driver will set gc->fwnode for each port corresponding to a child node under a GPIO device, so gc->gpiodev->dev will be assigned the value of each child node in gpiochip_add_data(). gpio-dwapb.c: 128,31 static int dwapb_gpio_add_port(struct dwapb_gpio *gpio, struct dwapb_port_property *pp, unsigned int offs); port->gc.fwnode = pp->fwnode; 693,39 static int dwapb_gpio_probe; err = dwapb_gpio_add_port(gpio, &pdata->properties[i], i); When other drivers request GPIO pin resources through the GPIO device node provided by ACPI (corresponding to the parent node), the change of the matching object to gc->gpiodev->dev in acpi_gpiochip_find() only allows finding the value of each port (child node), resulting in a failed request. Reapply the condition of using gc->parent for match in acpi_gpio- chip_find() in the code can compatible with the problem of gpio-dwapb, and will not affect the two cases mentioned in the patch: 1. There is no setting for gc->fwnode. 2. The case that depends on using gc->fwnode for match. Fixes: 5062e4c ("gpiolib: acpi: use the fwnode in acpi_gpiochip_find()") Fixes: 067dbc1 ("gpiolib: acpi: Don't use GPIO chip fwnode in acpi_gpiochip_find()") Signed-off-by: lujunhua <lujunhua7@h-partners.com> Signed-off-by: Devyn Liu <liudingyuan@huawei.com> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Tested-by: Benjamin Tissoires <bentiss@kernel.org> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: huwentao <wentaohu0417@163.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit b3adc38 upstream. Move it to the header so that the implementation can be shared by the alternatives code. Signed-off-by: Joey Gouly <joey.gouly@arm.com> Cc: Will Deacon <will@kernel.org> Acked-by: Mark Rutland <mark.rutland@arm.com> Link: https://lore.kernel.org/r/20220830104833.34636-2-joey.gouly@arm.com Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Ze Zuo <zuoze1@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 4e3bca8 upstream. Make it possible to use alternatives in the vDSO, so that better implementations can be used if possible. Signed-off-by: Joey Gouly <joey.gouly@arm.com> Cc: Will Deacon <will@kernel.org> Cc: Vincenzo Frascino <vincenzo.frascino@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Link: https://lore.kernel.org/r/20220830104833.34636-3-joey.gouly@arm.com Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Ze Zuo <zuoze1@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 9025ceb upstream. If FEAT_ECV is implemented, the self-synchronized counter CNTVCTSS_EL0 can be used, removing the need for an ISB. Signed-off-by: Joey Gouly <joey.gouly@arm.com> Cc: Will Deacon <will@kernel.org> Cc: Vincenzo Frascino <vincenzo.frascino@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Andre Przywara <andre.przywara@arm.com> Acked-by: Mark Rutland <mark.rutland@arm.com> Link: https://lore.kernel.org/r/20220830104833.34636-4-joey.gouly@arm.com Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Ze Zuo <zuoze1@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit a96a7a7 upstream. The two symbols __alt_instructions and __alt_instructions_end are not used, since the vDSO patching code looks for the '.altinstructions' ELF section directly. Remove the unused linker symbols. Fixes: 4e3bca8 ("arm64: alternative: patch alternatives in the vDSO") Signed-off-by: Jisheng Zhang <jszhang@kernel.org> Link: https://lore.kernel.org/r/20230726173619.3732-1-jszhang@kernel.org Signed-off-by: Will Deacon <will@kernel.org> Signed-off-by: Ze Zuo <zuoze1@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
commit 33060a6 upstream. We use a local variable hwcap to refer to the element of the hwcaps array which we are currently checking. When checking for the relevant hwcap bit being set in testing we were dereferencing hwcaps rather than hwcap in fetching the AT_HWCAP to use, which is perfectly valid C but means we were always checking the bit was set in the hwcap for whichever feature is first in the array. Remove the stray s. Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20220907113400.12982-1-broonie@kernel.org Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Qi Xi <xiqi2@huawei.com> Signed-off-by: slim6882 <yangjunshuo@huawei.com>
7994e20 to
5bd5840
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
hibmc-drm:
drm: Plumb debugfs_init through to panels
drm/ast: Implement polling for VGA and SIL164 connectors
drm/hisilicon/hibmc: add dp aux in hibmc drivers
drm/hisilicon/hibmc: add dp link moduel in hibmc drivers
drm/hisilicon/hibmc: add dp hw moduel in hibmc driver
drm/hisilicon/hibmc: refactored struct hibmc_drm_private
drm/hisilicon/hibmc: add dp module in hibmc
drm/hisilicon/hibmc: Replace module initialization with DRM helpers
drm/hisilicon/hibmc: Fix preferred depth and bpp
drm/hisilicon/hibmc: Restructuring the header dp_reg.h
drm/hisilicon/hibmc: Add dp serdes cfg to adjust serdes rate, voltage and pre-emphasis
drm/hisilicon/hibmc: Add dp serdes cfg in dp process
drm/hisilicon/hibmc: Refactor the member of drm_aux in struct hibmc_dp
drm/hisilicon/hibmc: Getting connector info and EDID by using AUX channel
drm/hisilicon/hibmc: Add colorbar-cfg feature and its debugfs file
drm/hisilicon/hibmc: Enable this hot plug detect of irq feature
drm/hisilicon/hibmc: Add MSI irq getting and requesting for HPD
drm/hisilicon/hibmc: Add vga connector detect functions
drm/hisilicon/hibmc: fix the i2c device resource leak when vdac init failed
drm/hisilicon/hibmc: fix irq_request()'s irq name variable is local
drm/hisilicon/hibmc: fix the hibmc loaded failed bug
drm/hisilicon/hibmc: fix rare monitors cannot display problem
drm/hisilicon/hibmc: fix dp and vga cannot show together
drm/hisilicon/hibmc: select CONFIG_DRM_DISPLAY_DP_HELPER
drm/hisilicon/hibmc: fix dp probabilistical detect errors after HPD irq
drm/hisilicon/hibmc: add dp mode valid check
drm/hisilicon/hibmc: fix no showing problem with loading hibmc manually
drm/hisilicon/hibmc: Adding reset colorbar cfg in dp init.
cpu-arch:
kselftest/arm64: Add a test program to exercise the syscall ABI
kselftest/arm64: Add simple hwcap validation
selftests/arm64: add HWCAP2_HBC test
arm64: trap implementation defined functionality in userspace
arm64: add HWCAP for FEAT_HBC (hinted conditional branches)
arm64: Add feature detection for fine grained traps
arm64/sysreg: Update ID_AA64MMFR1_EL1 register
arm64: setup: name 'tcr2' register
arm64/mm: Replace an open coding with ID_AA64MMFR1_EL1_HAFDBS_MASK
arm64: Add support for FEAT_HAFT
arm64: Enable ARCH_HAS_NONLEAF_PMD_YOUNG
arm64: pgtable: Warn unexpected pmdp_test_and_clear_young()
KVM: arm64: initialize HCRX_EL2
arm64/hwcap: Document allocation of upper bits of AT_HWCAP
arm64/cpufeature: Store elf_hwcaps as a bitmap rather than unsigned long
timer:
tick/broadcast: Make takeover of broadcast hrtimer reliable
tick/broadcast: Move per CPU pointer access into the atomic section
PCIe:
hwtracing: hisi_ptt: Fix up for "iommu/dma: Make header private"
hwtracing: hisi_ptt: Optimize the trace data committing
PCI/DPC: Ignore Surprise Down error on hot removal
perf hisi-ptt: Fix memory leak in lseek failure handling
drivers/perf: hisi_pcie: Export supported Root Ports [bdf_min, bdf_max]
cpufreq:
cpufreq: Support per-policy performance boost
cpufreq: Fix per-policy boost behavior on SoCs using cpufreq_boost_set_sw()
cpufreq: Allow drivers to advertise boost enabled
cpufreq: Introduce a more generic way to set default per-policy boost flag
cpufreq: CPPC: Fix wrong max_freq in policy initialization
cpufreq: ACPI: Defer setting boost MSRs
cpufreq: ACPI: Only set boost MSRs on supported CPUs
cpufreq: ACPI: Mark boost policy as enabled when setting boost
cpufreq: ACPI: Remove set_boost in acpi_cpufreq_cpu_init()
cpufreq: prevent NULL dereference in cpufreq_online()
cpufreq: governor: Fix negative 'idle_time' handling in dbs_update()
cpufreq: Fix re-boost issue after hotplugging a CPU
arch_topology: Introduce thermal pressure update function
sched/topology: Add a new arch_scale_freq_ref() method
topology: Set capacity_freq_ref in all cases
arch_topology: init capacity_freq_ref to 0
cpufreq: Allow arch_freq_get_on_cpu to return an error
cpufreq: Introduce an optional cpuinfo_avg_freq sysfs entry
arm64: Provide an AMU-based version of arch_freq_get_on_cpu
arm64: Update AMU-based freq scale factor on entering idle
arm64: Utilize for_each_cpu_wrap for reference lookup
arch_topology: obtain cpu capacity using information from CPPC
cpufreq/cppc: Set the frequency used for computing the capacity
arm64/amu: Use capacity_ref_freq() to set AMU ratio
cpufreq/cppc: Move and rename cppc_cpufreq_{perf_to_khz|khz_to_perf}()
arm64, topology: enable use of init_cpu_capacity_cppc()
cpufreq: ACPI: Remove unused variables 'acpi_cpufreq_online' and 'ret'
cpufreq: ACPI: Re-sync CPU boost state on system resume
perf:
perf arm-spe: Save context ID in record
tools: arm64: Import sysreg.h
arm64: perf: Simplify registration boilerplate
tools arm64: Import cputype.h
perf cpumap: Add is_subset function
KVM/arm64: Don't emulate a PMU for 32-bit guests if feature not set
arm64/sysreg: Introduce helpers for access to sysreg fields
perf arm64: Add missing -I for tools/arch/arm64/include/ to find asm/sysreg.h when building arm_spe.h
perf tools: Sync addition of PERF_MEM_SNOOPX_PEER
perf arm-spe: Use SPE data source for neoverse cores
perf: Add system error and not in transaction branch types
perf: Extend branch type classification
perf: Capture branch privilege information
perf: Add PERF_BR_NEW_ARCH_[N] map for BRBE on arm64 platform
perf: Consolidate branch sample filter helpers
perf/uapi: Define PERF_MEM_SNOOPX_PEER in kernel header file
perf stat: Add struct perf_stat_aggr to perf_stat_evsel
perf record: Add remaining branch filters: "no_cycles", "no_flags" & "hw_index"
perf pmu: Remove duplication around EVENT_SOURCE_DEVICE_PATH
perf arm-spe: Refactor arm-spe to support operation packet type
dmaengine: ioat: Free up __cleanup() name
perf cpumap: Add intersect function
perf pmu: Add CPU map for "cpu" PMUs
drivers/perf: hisi: Add support for HiSilicon H60PA and PAv3 PMU driver
drivers/perf: hisi: Add support for HiSilicon UC PMU driver
perf test bpf: Address error about non-null argument for epoll_pwait 2nd arg
perf header: Fix one memory leakage in perf_event__fprintf_event_update()
KVM: arm64: PMU: Add a helper to read a vCPU's PMCR_EL0
drivers: perf: arm_pmuv3: Read PMMIR_EL1 unconditionally
drivers: perf: arm_pmuv3: Drop some unused arguments from armv8_pmu_init()
arm: perf: Remove inlines from arm_pmuv3.c
arm: perf/kvm: Use GENMASK for ARMV8_PMU_PMCR_N
arm: perf: Use GENMASK for PMMIR fields
arm: perf: Convert remaining fields to use GENMASK
arm64: perf: Include threshold control fields in PMEVTYPER mask
arm: pmu: Share user ABI format mechanism with SPE
arm: pmu: Move error message and -EOPNOTSUPP to individual PMUs
arm64: perf: Add support for event counting threshold
arm: perf: Fix ARCH=arm build with GCC
uapi/auxvec: Define AT_HWCAP3 and AT_HWCAP4 aux vector, entries
arm64: arm_pmuv3: Correctly extract and check the PMUVer
perf arm: Workaround ARM PMUs cpu maps having offline cpus
drivers: arch_topology: Refactor do-while loops
perf: arm_pmuv3: Avoid assigning fixed cycle counter with threshold
perf stat: Display iostat headers correctly
binfmt_elf: Wire up AT_HWCAP3 at AT_HWCAP4
tools headers arm64: Sync arm64's cputype.h with the kernel sources
drivers/perf: hisi: Define a symbol namespace for HiSilicon Uncore PMUs
drivers/perf: hisi: Don't update the associated_cpus on CPU offline
drivers/perf: hisi: Migrate to one online CPU if no associated one online
drivers/perf: hisi: Refactor the detection of associated CPUs
drivers/perf: hisi: Extract topology information to a separate structure
drivers/perf: hisi: Add a common function to retrieve topology from firmware
drivers/perf: hisi: Provide a generic implementation of cpumask/identifier
drivers/perf: hisi: Export associated CPUs of each PMU through sysfs
drivers/perf: hisi: Fix incorrect variable name "hha_pmu" in DDRC PMU driver
drivers/perf: hisi: Delete redundant blank line of DDRC PMU
perf arm-spe: Add support for SPE Data Source packet on HiSilicon HIP12
arm64/sysreg: Add BRBE registers and fields
drivers/perf: hisi: Simplify the probe process for each DDRC version
drivers/perf: hisi: Add support for HiSilicon DDRC v3 PMU driver
drivers/perf: hisi: Use ACPI driver_data to retrieve SLLC PMU information
drivers/perf: hisi: Add support for HiSilicon SLLC v3 PMU driver
drivers/perf: hisi: Relax the event number check of v2 PMUs
drivers/perf: hisi: Support PMUs with no interrupt
drivers/perf: hisi: Add support for HiSilicon NoC PMU
drivers/perf: hisi: Add support for HiSilicon MN PMU driver
drivers/perf: hisi: Relax the event ID check in the framework
drivers/perf: hisi: Export hisi_uncore_pmu_isr()
drivers/perf: hisi: Simplify the probe process of each L3C PMU version
drivers/perf: hisi: Extract the event filter check of L3C PMU
drivers/perf: hisi: Extend the field of tt_core
drivers/perf: hisi: Refactor the event configuration of L3C PMU
drivers/perf: hisi: Add support for L3C PMU v3
acpi_power_meter:
ACPI: IPMI: Add helper to wait for when SMI is selected
hwmon: (acpi_power_meter) Ensure IPMI space handler is ready on Dell systems
hwmon: (acpi_power_meter) Fix fail to load module on platform without _PMD method
hwmon: (acpi_power_meter) Fix uninitialized variables
hwmon: (acpi_power_meter) Fix update the power trip points on failure
hwmon: (acpi_power_meter) Fix a check for the return value of read_domain_devices().
hwmon: (acpi_power_meter) Fix the fake power alarm reporting
hwmon: Fix the missing of 'average' word in hwmon_power_attr_templates
hwmon: (acpi_power_meter) Replace the deprecated hwmon_device_register