[chrome-os:chromeos-5.15 989/2818] mm/low-mem-notify.c:53:6: error: no previous prototype for 'low_mem_notify'
by kernel test robot
tree: https://chromium.googlesource.com/chromiumos/third_party/kernel chromeos-5.15
head: b4852fbf90916fdc2f1e0e282e100f7e0e889d77
commit: 467d55003e7cac35a55032ae02df445c18566434 [989/2818] CHROMIUM: mm: move low memory code
config: arm-chromiumos-arm-customedconfig-chrome-os:chromeos-5.15:b4852fbf90916fdc2f1e0e282e100f7e0e889d77 (https://download.01.org/0day-ci/archive/20211212/202112120914.wBfKM0Ox-lk...)
compiler: arm-linux-gnueabi-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git remote add chrome-os https://chromium.googlesource.com/chromiumos/third_party/kernel
git fetch --no-tags chrome-os chromeos-5.15
git checkout 467d55003e7cac35a55032ae02df445c18566434
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arm SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> mm/low-mem-notify.c:53:6: error: no previous prototype for 'low_mem_notify' [-Werror=missing-prototypes]
53 | void low_mem_notify(void)
| ^~~~~~~~~~~~~~
>> mm/low-mem-notify.c:121:6: error: no previous prototype for 'low_mem_check' [-Werror=missing-prototypes]
121 | bool low_mem_check(void)
| ^~~~~~~~~~~~~
cc1: all warnings being treated as errors
vim +/low_mem_notify +53 mm/low-mem-notify.c
6f9d293215315a Luigi Semenzato 2014-04-03 52
6f9d293215315a Luigi Semenzato 2014-04-03 @53 void low_mem_notify(void)
6f9d293215315a Luigi Semenzato 2014-04-03 54 {
6f9d293215315a Luigi Semenzato 2014-04-03 55 atomic_set(&low_mem_state, true);
6f9d293215315a Luigi Semenzato 2014-04-03 56 wake_up(&low_mem_wait);
6f9d293215315a Luigi Semenzato 2014-04-03 57 }
6f9d293215315a Luigi Semenzato 2014-04-03 58
467d55003e7cac Yu Zhao 2019-11-10 59 /*
467d55003e7cac Yu Zhao 2019-11-10 60 * Compute available memory used by files that can be reclaimed quickly.
467d55003e7cac Yu Zhao 2019-11-10 61 */
467d55003e7cac Yu Zhao 2019-11-10 62 static unsigned long get_available_file_mem(void)
6f9d293215315a Luigi Semenzato 2014-04-03 63 {
467d55003e7cac Yu Zhao 2019-11-10 64 unsigned long file_mem =
467d55003e7cac Yu Zhao 2019-11-10 65 global_node_page_state(NR_ACTIVE_FILE) +
467d55003e7cac Yu Zhao 2019-11-10 66 global_node_page_state(NR_INACTIVE_FILE);
467d55003e7cac Yu Zhao 2019-11-10 67 unsigned long dirty_mem = global_node_page_state(NR_FILE_DIRTY);
467d55003e7cac Yu Zhao 2019-11-10 68 unsigned long min_file_mem = min_filelist_kbytes >> (PAGE_SHIFT - 10);
467d55003e7cac Yu Zhao 2019-11-10 69 unsigned long clean_file_mem = file_mem > dirty_mem ?
467d55003e7cac Yu Zhao 2019-11-10 70 file_mem - dirty_mem : 0;
467d55003e7cac Yu Zhao 2019-11-10 71 /* Conservatively estimate the amount of available_file_mem */
467d55003e7cac Yu Zhao 2019-11-10 72 unsigned long available_file_mem = clean_file_mem > min_file_mem ?
467d55003e7cac Yu Zhao 2019-11-10 73 clean_file_mem - min_file_mem : 0;
467d55003e7cac Yu Zhao 2019-11-10 74 return available_file_mem;
467d55003e7cac Yu Zhao 2019-11-10 75 }
6f9d293215315a Luigi Semenzato 2014-04-03 76
467d55003e7cac Yu Zhao 2019-11-10 77 /*
467d55003e7cac Yu Zhao 2019-11-10 78 * Available anonymous memory.
467d55003e7cac Yu Zhao 2019-11-10 79 */
467d55003e7cac Yu Zhao 2019-11-10 80 static unsigned long get_available_anon_mem(void)
467d55003e7cac Yu Zhao 2019-11-10 81 {
467d55003e7cac Yu Zhao 2019-11-10 82 return global_node_page_state(NR_ACTIVE_ANON) +
467d55003e7cac Yu Zhao 2019-11-10 83 global_node_page_state(NR_INACTIVE_ANON);
6f9d293215315a Luigi Semenzato 2014-04-03 84 }
6f9d293215315a Luigi Semenzato 2014-04-03 85
467d55003e7cac Yu Zhao 2019-11-10 86 /*
467d55003e7cac Yu Zhao 2019-11-10 87 * Compute "available" memory, that is either free memory or memory that can be
467d55003e7cac Yu Zhao 2019-11-10 88 * reclaimed quickly, adjusted for the presence of swap.
467d55003e7cac Yu Zhao 2019-11-10 89 */
467d55003e7cac Yu Zhao 2019-11-10 90 static unsigned long get_available_mem_adj(void)
467d55003e7cac Yu Zhao 2019-11-10 91 {
467d55003e7cac Yu Zhao 2019-11-10 92 /* free_mem is completely unallocated; clean file-backed memory
467d55003e7cac Yu Zhao 2019-11-10 93 * (file_mem - dirty_mem) is easy to reclaim, except for the last
467d55003e7cac Yu Zhao 2019-11-10 94 * min_filelist_kbytes. totalreserve_pages is the reserve of pages that
467d55003e7cac Yu Zhao 2019-11-10 95 * are not available to user space.
467d55003e7cac Yu Zhao 2019-11-10 96 */
467d55003e7cac Yu Zhao 2019-11-10 97 unsigned long raw_free_mem = global_zone_page_state(NR_FREE_PAGES);
467d55003e7cac Yu Zhao 2019-11-10 98 unsigned long free_mem = raw_free_mem > totalreserve_pages ?
467d55003e7cac Yu Zhao 2019-11-10 99 raw_free_mem - totalreserve_pages : 0;
467d55003e7cac Yu Zhao 2019-11-10 100 unsigned long available_mem = free_mem + get_available_file_mem();
467d55003e7cac Yu Zhao 2019-11-10 101 unsigned long swappable_pages = min_t(unsigned long,
467d55003e7cac Yu Zhao 2019-11-10 102 get_nr_swap_pages(), get_available_anon_mem());
467d55003e7cac Yu Zhao 2019-11-10 103 /*
467d55003e7cac Yu Zhao 2019-11-10 104 * The contribution of swap is reduced by a factor of
467d55003e7cac Yu Zhao 2019-11-10 105 * low_mem_ram_vs_swap_weight.
467d55003e7cac Yu Zhao 2019-11-10 106 */
467d55003e7cac Yu Zhao 2019-11-10 107 return available_mem + swappable_pages / low_mem_ram_vs_swap_weight;
467d55003e7cac Yu Zhao 2019-11-10 108 }
467d55003e7cac Yu Zhao 2019-11-10 109
467d55003e7cac Yu Zhao 2019-11-10 110 #ifdef CONFIG_SYSFS
467d55003e7cac Yu Zhao 2019-11-10 111 static void low_mem_threshold_notify(void);
467d55003e7cac Yu Zhao 2019-11-10 112 #else
467d55003e7cac Yu Zhao 2019-11-10 113 static void low_mem_threshold_notify(void)
467d55003e7cac Yu Zhao 2019-11-10 114 {
467d55003e7cac Yu Zhao 2019-11-10 115 }
467d55003e7cac Yu Zhao 2019-11-10 116 #endif
467d55003e7cac Yu Zhao 2019-11-10 117
467d55003e7cac Yu Zhao 2019-11-10 118 /*
467d55003e7cac Yu Zhao 2019-11-10 119 * Returns TRUE if we are in a low memory state.
467d55003e7cac Yu Zhao 2019-11-10 120 */
467d55003e7cac Yu Zhao 2019-11-10 @121 bool low_mem_check(void)
467d55003e7cac Yu Zhao 2019-11-10 122 {
467d55003e7cac Yu Zhao 2019-11-10 123 static bool was_low_mem; /* = false, as per style guide */
467d55003e7cac Yu Zhao 2019-11-10 124 static atomic_t in_low_mem_check = ATOMIC_INIT(0);
467d55003e7cac Yu Zhao 2019-11-10 125 /* last observed threshold */
467d55003e7cac Yu Zhao 2019-11-10 126 static unsigned int low_mem_threshold_last = UINT_MAX;
467d55003e7cac Yu Zhao 2019-11-10 127 /* Limit logging low memory to once per second. */
467d55003e7cac Yu Zhao 2019-11-10 128 static DEFINE_RATELIMIT_STATE(low_mem_logging_ratelimit, 1 * HZ, 1);
467d55003e7cac Yu Zhao 2019-11-10 129
467d55003e7cac Yu Zhao 2019-11-10 130 /* We declare a low-memory condition when a combination of RAM and swap
467d55003e7cac Yu Zhao 2019-11-10 131 * space is low.
467d55003e7cac Yu Zhao 2019-11-10 132 */
467d55003e7cac Yu Zhao 2019-11-10 133 unsigned long available_mem = get_available_mem_adj();
467d55003e7cac Yu Zhao 2019-11-10 134 /*
467d55003e7cac Yu Zhao 2019-11-10 135 * For backwards compatibility with the older margin interface, we will
467d55003e7cac Yu Zhao 2019-11-10 136 * trigger the /dev/chromeos-low_mem device when we are below the
467d55003e7cac Yu Zhao 2019-11-10 137 * lowest threshold
467d55003e7cac Yu Zhao 2019-11-10 138 */
467d55003e7cac Yu Zhao 2019-11-10 139 bool is_low_mem = available_mem < low_mem_thresholds[0];
467d55003e7cac Yu Zhao 2019-11-10 140 unsigned int threshold_lowest = UINT_MAX;
467d55003e7cac Yu Zhao 2019-11-10 141 int i;
467d55003e7cac Yu Zhao 2019-11-10 142
467d55003e7cac Yu Zhao 2019-11-10 143 if (!low_mem_margin_enabled)
467d55003e7cac Yu Zhao 2019-11-10 144 return false;
467d55003e7cac Yu Zhao 2019-11-10 145
467d55003e7cac Yu Zhao 2019-11-10 146 if (atomic_read(&in_low_mem_check) || atomic_xchg(&in_low_mem_check, 1))
467d55003e7cac Yu Zhao 2019-11-10 147 return was_low_mem;
467d55003e7cac Yu Zhao 2019-11-10 148
467d55003e7cac Yu Zhao 2019-11-10 149 if (unlikely(is_low_mem && !was_low_mem) &&
467d55003e7cac Yu Zhao 2019-11-10 150 __ratelimit(&low_mem_logging_ratelimit)) {
467d55003e7cac Yu Zhao 2019-11-10 151 pr_info("entering low_mem (avail RAM = %lu kB, avail swap %lu kB, avail file %lu kB, anon mem: %lu kB)\n",
467d55003e7cac Yu Zhao 2019-11-10 152 available_mem * PAGE_SIZE / 1024,
467d55003e7cac Yu Zhao 2019-11-10 153 get_nr_swap_pages() * PAGE_SIZE / 1024,
467d55003e7cac Yu Zhao 2019-11-10 154 get_available_file_mem() * PAGE_SIZE / 1024,
467d55003e7cac Yu Zhao 2019-11-10 155 get_available_anon_mem() * PAGE_SIZE / 1024);
467d55003e7cac Yu Zhao 2019-11-10 156 }
467d55003e7cac Yu Zhao 2019-11-10 157 was_low_mem = is_low_mem;
467d55003e7cac Yu Zhao 2019-11-10 158
467d55003e7cac Yu Zhao 2019-11-10 159 if (is_low_mem)
467d55003e7cac Yu Zhao 2019-11-10 160 low_mem_notify();
467d55003e7cac Yu Zhao 2019-11-10 161
467d55003e7cac Yu Zhao 2019-11-10 162 for (i = 0; i < low_mem_threshold_count; i++) {
467d55003e7cac Yu Zhao 2019-11-10 163 if (available_mem < low_mem_thresholds[i]) {
467d55003e7cac Yu Zhao 2019-11-10 164 threshold_lowest = i;
467d55003e7cac Yu Zhao 2019-11-10 165 break;
467d55003e7cac Yu Zhao 2019-11-10 166 }
467d55003e7cac Yu Zhao 2019-11-10 167 }
467d55003e7cac Yu Zhao 2019-11-10 168
467d55003e7cac Yu Zhao 2019-11-10 169 /* we crossed one or more thresholds */
467d55003e7cac Yu Zhao 2019-11-10 170 if (unlikely(threshold_lowest < low_mem_threshold_last))
467d55003e7cac Yu Zhao 2019-11-10 171 low_mem_threshold_notify();
467d55003e7cac Yu Zhao 2019-11-10 172
467d55003e7cac Yu Zhao 2019-11-10 173 low_mem_threshold_last = threshold_lowest;
467d55003e7cac Yu Zhao 2019-11-10 174
467d55003e7cac Yu Zhao 2019-11-10 175 atomic_set(&in_low_mem_check, 0);
467d55003e7cac Yu Zhao 2019-11-10 176
467d55003e7cac Yu Zhao 2019-11-10 177 return is_low_mem;
467d55003e7cac Yu Zhao 2019-11-10 178 }
467d55003e7cac Yu Zhao 2019-11-10 179
:::::: The code at line 53 was first introduced by commit
:::::: 6f9d293215315aefb091456a2eb8c2799ff1232a CHROMIUM: Add /dev/low-mem device for low-memory notification.
:::::: TO: Luigi Semenzato <semenzato(a)chromium.org>
:::::: CC: Guenter Roeck <groeck(a)chromium.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
9 months, 1 week
[superna9999:amlogic/v5.17/g12-dsi 6/23] drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:58:23: error: 'encoder_dsi' undeclared
by kernel test robot
tree: https://github.com/superna9999/linux amlogic/v5.17/g12-dsi
head: 62dac9179f2937dc08bffe08d15c6846bc4aedb4
commit: 02c9727464cf0ef4cebca0197a0f7395be6371f7 [6/23] fixup! drm/meson: add support for MIPI-DSI transceiver
config: arm64-allyesconfig (https://download.01.org/0day-ci/archive/20211212/202112120900.1gurSnwO-lk...)
compiler: aarch64-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/superna9999/linux/commit/02c9727464cf0ef4cebca0197a0f7...
git remote add superna9999 https://github.com/superna9999/linux
git fetch --no-tags superna9999 amlogic/v5.17/g12-dsi
git checkout 02c9727464cf0ef4cebca0197a0f7395be6371f7
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arm64 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Note: the superna9999/amlogic/v5.17/g12-dsi HEAD 62dac9179f2937dc08bffe08d15c6846bc4aedb4 builds fine.
It only hurts bisectability.
All errors (new ones prefixed by >>):
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c: In function 'dw_mipi_dsi_phy_init':
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:58:23: error: 'encoder_dsi' undeclared (first use in this function)
58 | phy_configure(encoder_dsi->phy, &mipi_dsi->phy_opts);
| ^~~~~~~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:58:23: note: each undeclared identifier is reported only once for each function it appears in
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:68:9: error: implicit declaration of function 'meson_dw_mipi_dsi_hw_init'; did you mean 'dw_mipi_dsi_phy_init'? [-Werror=implicit-function-declaration]
68 | meson_dw_mipi_dsi_hw_init(mipi_dsi);
| ^~~~~~~~~~~~~~~~~~~~~~~~~
| dw_mipi_dsi_phy_init
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:72:35: error: 'COLOR_24BIT' undeclared (first use in this function)
72 | dpi_data_format = COLOR_24BIT;
| ^~~~~~~~~~~
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:73:35: error: 'MIPI_DSI_VENC_COLOR_24B' undeclared (first use in this function)
73 | venc_data_width = MIPI_DSI_VENC_COLOR_24B;
| ^~~~~~~~~~~~~~~~~~~~~~~
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:76:35: error: 'COLOR_18BIT_CFG_2' undeclared (first use in this function)
76 | dpi_data_format = COLOR_18BIT_CFG_2;
| ^~~~~~~~~~~~~~~~~
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:77:35: error: 'MIPI_DSI_VENC_COLOR_18B' undeclared (first use in this function)
77 | venc_data_width = MIPI_DSI_VENC_COLOR_18B;
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:70:9: warning: enumeration value 'MIPI_DSI_FMT_RGB666_PACKED' not handled in switch [-Wswitch]
70 | switch (mipi_dsi->dsi_device->format) {
| ^~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:70:9: warning: enumeration value 'MIPI_DSI_FMT_RGB565' not handled in switch [-Wswitch]
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:89:59: error: macro "writel_relaxed" passed 3 arguments, but takes just 2
89 | mipi_dsi->base + MIPI_DSI_TOP_CNTL);
| ^
In file included from include/linux/io.h:13,
from include/linux/irq.h:20,
from include/asm-generic/hardirq.h:17,
from arch/arm64/include/asm/hardirq.h:17,
from include/linux/hardirq.h:11,
from include/linux/interrupt.h:11,
from include/linux/kernel_stat.h:9,
from include/linux/cgroup.h:26,
from include/linux/memcontrol.h:13,
from include/linux/swap.h:9,
from include/linux/suspend.h:5,
from include/linux/regulator/consumer.h:35,
from include/linux/phy/phy.h:17,
from drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:15:
arch/arm64/include/asm/io.h:127: note: macro "writel_relaxed" defined here
127 | #define writel_relaxed(v,c) ((void)__raw_writel((__force u32)cpu_to_le32(v),(c)))
|
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:82:9: error: 'writel_relaxed' undeclared (first use in this function)
82 | writel_relaxed((dpi_data_format << BIT_DPI_COLOR_MODE) |
| ^~~~~~~~~~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:55:27: warning: unused variable 'priv' [-Wunused-variable]
55 | struct meson_drm *priv = mipi_dsi->priv;
| ^~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:54:39: warning: variable 'venc_data_width' set but not used [-Wunused-but-set-variable]
54 | unsigned int dpi_data_format, venc_data_width;
| ^~~~~~~~~~~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:54:22: warning: variable 'dpi_data_format' set but not used [-Wunused-but-set-variable]
54 | unsigned int dpi_data_format, venc_data_width;
| ^~~~~~~~~~~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c: In function 'dw_mipi_dsi_get_lane_mbps':
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:111:24: warning: assignment discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
111 | mipi_dsi->mode = mode;
| ^
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:113:15: error: implicit declaration of function 'encoder_dsi_pixel_format_to_bpp'; did you mean 'mipi_dsi_pixel_format_to_bpp'? [-Werror=implicit-function-declaration]
113 | bpp = encoder_dsi_pixel_format_to_bpp(mipi_dsi->dsi_device->format);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| mipi_dsi_pixel_format_to_bpp
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:116:47: error: 'encoder_dsi' undeclared (first use in this function)
116 | bpp, encoder_dsi->dsi_device->lanes,
| ^~~~~~~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c: In function 'meson_dw_mipi_dsi_bind':
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:161:13: warning: unused variable 'ret' [-Wunused-variable]
161 | int ret;
| ^~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:160:29: warning: unused variable 'encoder' [-Wunused-variable]
160 | struct drm_encoder *encoder;
| ^~~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c: At top level:
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:176:13: warning: conflicting types for 'meson_dw_mipi_dsi_hw_init'; have 'void(struct meson_dw_mipi_dsi *)'
176 | static void meson_dw_mipi_dsi_hw_init(struct meson_dw_mipi_dsi *mipi_dsi)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:176:13: error: static declaration of 'meson_dw_mipi_dsi_hw_init' follows non-static declaration
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:68:9: note: previous implicit declaration of 'meson_dw_mipi_dsi_hw_init' with type 'void(struct meson_dw_mipi_dsi *)'
68 | meson_dw_mipi_dsi_hw_init(mipi_dsi);
| ^~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c: In function 'meson_dw_mipi_dsi_host_attach':
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:200:9: error: implicit declaration of function 'witch' [-Werror=implicit-function-declaration]
200 | witch (device->format) {
| ^~~~~
>> drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:200:31: error: expected ';' before '{' token
200 | witch (device->format) {
| ^~
| ;
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:196:13: warning: unused variable 'reg' [-Wunused-variable]
196 | u32 reg;
| ^~~
At top level:
drivers/gpu/drm/meson/meson_dw_mipi_dsi.c:176:13: warning: 'meson_dw_mipi_dsi_hw_init' defined but not used [-Wunused-function]
176 | static void meson_dw_mipi_dsi_hw_init(struct meson_dw_mipi_dsi *mipi_dsi)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +/encoder_dsi +58 drivers/gpu/drm/meson/meson_dw_mipi_dsi.c
47
48 #define encoder_to_meson_dw_mipi_dsi(x) \
49 container_of(x, struct meson_dw_mipi_dsi, encoder)
50
51 static int dw_mipi_dsi_phy_init(void *priv_data)
52 {
53 struct meson_dw_mipi_dsi *mipi_dsi = priv_data;
54 unsigned int dpi_data_format, venc_data_width;
55 struct meson_drm *priv = mipi_dsi->priv;
56 int ret;
57
> 58 phy_configure(encoder_dsi->phy, &mipi_dsi->phy_opts);
59
60 ret = clk_set_rate(mipi_dsi->px_clk, mipi_dsi->phy_opts.mipi_dphy.hs_clk_rate);
61 if (ret) {
62 pr_err("Failed to set DSI PLL rate %lu\n",
63 mipi_dsi->phy_opts.mipi_dphy.hs_clk_rate);
64
65 return ret;
66 }
67
> 68 meson_dw_mipi_dsi_hw_init(mipi_dsi);
69
70 switch (mipi_dsi->dsi_device->format) {
71 case MIPI_DSI_FMT_RGB888:
> 72 dpi_data_format = COLOR_24BIT;
> 73 venc_data_width = MIPI_DSI_VENC_COLOR_24B;
74 break;
75 case MIPI_DSI_FMT_RGB666:
> 76 dpi_data_format = COLOR_18BIT_CFG_2;
> 77 venc_data_width = MIPI_DSI_VENC_COLOR_18B;
78 break;
79 };
80
81 /* Configure color format for DPI register */
> 82 writel_relaxed((dpi_data_format << BIT_DPI_COLOR_MODE) |
83 (venc_data_width << BIT_IN_COLOR_MODE) |
84 0 << BIT_COMP0_SEL |
85 1 << BIT_COMP1_SEL |
86 2 << BIT_COMP2_SEL,
87 (mipi_dsi->mode->flags & DRM_MODE_FLAG_NHSYNC ? 0 : BIT(BIT_HSYNC_POL)) |
88 (mipi_dsi->mode->flags & DRM_MODE_FLAG_NVSYNC ? 0 : BIT(BIT_VSYNC_POL)),
> 89 mipi_dsi->base + MIPI_DSI_TOP_CNTL);
90
91 phy_power_on(mipi_dsi->phy);
92
93 return 0;
94 }
95
96 static void dw_mipi_dsi_phy_power_off(void *priv_data)
97 {
98 struct meson_dw_mipi_dsi *mipi_dsi = priv_data;
99
100 phy_power_off(mipi_dsi->phy);
101 }
102
103 static int
104 dw_mipi_dsi_get_lane_mbps(void *priv_data, const struct drm_display_mode *mode,
105 unsigned long mode_flags, u32 lanes, u32 format,
106 unsigned int *lane_mbps)
107 {
108 struct meson_dw_mipi_dsi *mipi_dsi = priv_data;
109 int bpp;
110
111 mipi_dsi->mode = mode;
112
> 113 bpp = encoder_dsi_pixel_format_to_bpp(mipi_dsi->dsi_device->format);
114
115 phy_mipi_dphy_get_default_config(mode->clock * 1000,
116 bpp, encoder_dsi->dsi_device->lanes,
117 &mipi_dsi->phy_opts.mipi_dphy);
118
119 *lane_mbps = mipi_dsi->phy_opts.mipi_dphy.hs_clk_rate / 1000000;
120
121 return 0;
122 }
123
124 static int
125 dw_mipi_dsi_phy_get_timing(void *priv_data, unsigned int lane_mbps,
126 struct dw_mipi_dsi_dphy_timing *timing)
127 {
128 /* TOFIX handle other cases */
129
130 timing->clk_lp2hs = 37;
131 timing->clk_hs2lp = 135;
132 timing->data_lp2hs = 50;
133 timing->data_hs2lp = 3;
134
135 return 0;
136 }
137
138 static int
139 dw_mipi_dsi_get_esc_clk_rate(void *priv_data, unsigned int *esc_clk_rate)
140 {
141 *esc_clk_rate = 4; /* Mhz */
142
143 return 0;
144 }
145
146 static const struct dw_mipi_dsi_phy_ops meson_dw_mipi_dsi_phy_ops = {
147 .init = dw_mipi_dsi_phy_init,
148 .power_off = dw_mipi_dsi_phy_power_off,
149 .get_lane_mbps = dw_mipi_dsi_get_lane_mbps,
150 .get_timing = dw_mipi_dsi_phy_get_timing,
151 .get_esc_clk_rate = dw_mipi_dsi_get_esc_clk_rate,
152 };
153
154 static int meson_dw_mipi_dsi_bind(struct device *dev, struct device *master,
155 void *data)
156 {
157 struct meson_dw_mipi_dsi *mipi_dsi = dev_get_drvdata(dev);
158 struct drm_device *drm = data;
159 struct meson_drm *priv = drm->dev_private;
160 struct drm_encoder *encoder;
161 int ret;
162
163 /* Check before if we are supposed to have a sub-device... */
164 if (!mipi_dsi->dsi_device)
165 return -EPROBE_DEFER;
166
167 mipi_dsi->priv = priv;
168
169 return 0;
170 }
171
172 static const struct component_ops meson_dw_mipi_dsi_ops = {
173 .bind = meson_dw_mipi_dsi_bind,
174 };
175
176 static void meson_dw_mipi_dsi_hw_init(struct meson_dw_mipi_dsi *mipi_dsi)
177 {
178 writel_relaxed((1 << 4) | (1 << 5) | (0 << 6),
179 mipi_dsi->base + MIPI_DSI_TOP_CNTL);
180
181 writel_bits_relaxed(0xf, 0xf,
182 mipi_dsi->base + MIPI_DSI_TOP_SW_RESET);
183 writel_bits_relaxed(0xf, 0,
184 mipi_dsi->base + MIPI_DSI_TOP_SW_RESET);
185
186 writel_bits_relaxed(0x3, 0x3,
187 mipi_dsi->base + MIPI_DSI_TOP_CLK_CNTL);
188
189 writel_relaxed(0, mipi_dsi->base + MIPI_DSI_TOP_MEM_PD);
190 }
191
192 static int meson_dw_mipi_dsi_host_attach(void *priv_data,
193 struct mipi_dsi_device *device)
194 {
195 struct meson_dw_mipi_dsi *mipi_dsi = priv_data;
196 u32 reg;
197
198 mipi_dsi->dsi_device = device;
199
> 200 witch (device->format) {
201 case MIPI_DSI_FMT_RGB888:
202 dpi_data_format = COLOR_24BIT;
203 venc_data_width = MIPI_DSI_VENC_COLOR_24B;
204 break;
205 case MIPI_DSI_FMT_RGB666:
206 dpi_data_format = COLOR_18BIT_CFG_2;
207 venc_data_width = MIPI_DSI_VENC_COLOR_18B;
208 break;
209 case MIPI_DSI_FMT_RGB666_PACKED:
210 case MIPI_DSI_FMT_RGB565:
211 DRM_DEV_ERROR(mipi_dsi->dev, "invalid pixel format %d\n", device->format);
212 return -EINVAL;
213 };
214
215 phy_init(mipi_dsi->phy);
216
217 return 0;
218 }
219
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
9 months, 1 week
drivers/irqchip/irq-sun6i-r.c:215:79: sparse: sparse: Using plain integer as NULL pointer
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: bbdff6d583be718935b613ab2a966cddaadf661f
commit: 4e34614636b31747b190488240a95647c227021f irqchip/sun6i-r: Use a stacked irqchip driver
date: 11 months ago
config: arm-allyesconfig (https://download.01.org/0day-ci/archive/20211212/202112120838.OtQsRmlP-lk...)
compiler: arm-linux-gnueabi-gcc (GCC) 11.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.4-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 4e34614636b31747b190488240a95647c227021f
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=arm SHELL=/bin/bash arch/arm/mach-socfpga/ drivers/dma/ drivers/edac/ drivers/gpu/drm/msm/ drivers/gpu/drm/tegra/ drivers/interconnect/qcom/ drivers/irqchip/ drivers/net/ethernet/mediatek/ drivers/net/vmxnet3/ drivers/net/wireless/mediatek/mt76/mt7915/ drivers/remoteproc/ drivers/scsi/bnx2fc/ drivers/scsi/lpfc/ drivers/staging/ fs/proc/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
>> drivers/irqchip/irq-sun6i-r.c:215:79: sparse: sparse: Using plain integer as NULL pointer
vim +215 drivers/irqchip/irq-sun6i-r.c
184
185 static int sun6i_r_intc_domain_alloc(struct irq_domain *domain,
186 unsigned int virq,
187 unsigned int nr_irqs, void *arg)
188 {
189 struct irq_fwspec *fwspec = arg;
190 struct irq_fwspec gic_fwspec;
191 unsigned long hwirq;
192 unsigned int type;
193 int i, ret;
194
195 ret = sun6i_r_intc_domain_translate(domain, fwspec, &hwirq, &type);
196 if (ret)
197 return ret;
198 if (hwirq + nr_irqs > SUN6I_NR_MUX_BITS)
199 return -EINVAL;
200
201 /* Construct a GIC-compatible fwspec from this fwspec. */
202 gic_fwspec = (struct irq_fwspec) {
203 .fwnode = domain->parent->fwnode,
204 .param_count = 3,
205 .param = { GIC_SPI, hwirq, type },
206 };
207
208 ret = irq_domain_alloc_irqs_parent(domain, virq, nr_irqs, &gic_fwspec);
209 if (ret)
210 return ret;
211
212 for (i = 0; i < nr_irqs; ++i, ++hwirq, ++virq) {
213 if (hwirq == nmi_hwirq) {
214 irq_domain_set_hwirq_and_chip(domain, virq, hwirq,
> 215 &sun6i_r_intc_nmi_chip, 0);
216 irq_set_handler(virq, handle_fasteoi_ack_irq);
217 } else {
218 /* Only the NMI is currently supported. */
219 return -EINVAL;
220 }
221 }
222
223 return 0;
224 }
225
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
9 months, 1 week
[chrome-os:chromeos-5.15 976/2818] kernel/sys.c:203:5: error: no previous prototype for 'ksys_setpriority'
by kernel test robot
tree: https://chromium.googlesource.com/chromiumos/third_party/kernel chromeos-5.15
head: b4852fbf90916fdc2f1e0e282e100f7e0e889d77
commit: aabdf8c83677b5a7a86f9501b98ba5c7fa290648 [976/2818] CHROMIUM: alt-syscall: Make required syscalls available for use
config: arm-chromiumos-arm-customedconfig-chrome-os:chromeos-5.15:b4852fbf90916fdc2f1e0e282e100f7e0e889d77 (https://download.01.org/0day-ci/archive/20211212/202112120809.hAd2Uwqx-lk...)
compiler: arm-linux-gnueabi-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git remote add chrome-os https://chromium.googlesource.com/chromiumos/third_party/kernel
git fetch --no-tags chrome-os chromeos-5.15
git checkout aabdf8c83677b5a7a86f9501b98ba5c7fa290648
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arm SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> kernel/sys.c:203:5: error: no previous prototype for 'ksys_setpriority' [-Werror=missing-prototypes]
203 | int ksys_setpriority(int which, int who, int niceval)
| ^~~~~~~~~~~~~~~~
>> kernel/sys.c:278:5: error: no previous prototype for 'ksys_getpriority' [-Werror=missing-prototypes]
278 | int ksys_getpriority(int which, int who)
| ^~~~~~~~~~~~~~~~
>> kernel/sys.c:2274:5: error: no previous prototype for 'ksys_prctl' [-Werror=missing-prototypes]
2274 | int ksys_prctl(int option, unsigned long arg2, unsigned long arg3,
| ^~~~~~~~~~
>> kernel/sys.c:2556:5: error: no previous prototype for 'ksys_getcpu' [-Werror=missing-prototypes]
2556 | int ksys_getcpu(unsigned __user *cpup, unsigned __user *nodep,
| ^~~~~~~~~~~
cc1: all warnings being treated as errors
--
>> kernel/time/time.c:354:5: error: no previous prototype for 'ksys_adjtimex_time32' [-Werror=missing-prototypes]
354 | int ksys_adjtimex_time32(struct old_timex32 __user * utp)
| ^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
>> kernel/time/posix-timers.c:1112:5: error: no previous prototype for 'ksys_clock_adjtime' [-Werror=missing-prototypes]
1112 | int ksys_clock_adjtime(const clockid_t which_clock,
| ^~~~~~~~~~~~~~~~~~
>> kernel/time/posix-timers.c:1188:5: error: no previous prototype for 'ksys_clock_adjtime32' [-Werror=missing-prototypes]
1188 | int ksys_clock_adjtime32(clockid_t which_clock, struct old_timex32 __user * utp)
| ^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
>> kernel/events/core.c:11987:5: error: no previous prototype for 'ksys_perf_event_open' [-Werror=missing-prototypes]
11987 | int ksys_perf_event_open(struct perf_event_attr __user * attr_uptr, pid_t pid,
| ^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
vim +/ksys_setpriority +203 kernel/sys.c
202
> 203 int ksys_setpriority(int which, int who, int niceval)
204 {
205 struct task_struct *g, *p;
206 struct user_struct *user;
207 const struct cred *cred = current_cred();
208 int error = -EINVAL;
209 struct pid *pgrp;
210 kuid_t uid;
211
212 if (which > PRIO_USER || which < PRIO_PROCESS)
213 goto out;
214
215 /* normalize: avoid signed division (rounding problems) */
216 error = -ESRCH;
217 if (niceval < MIN_NICE)
218 niceval = MIN_NICE;
219 if (niceval > MAX_NICE)
220 niceval = MAX_NICE;
221
222 rcu_read_lock();
223 read_lock(&tasklist_lock);
224 switch (which) {
225 case PRIO_PROCESS:
226 if (who)
227 p = find_task_by_vpid(who);
228 else
229 p = current;
230 if (p)
231 error = set_one_prio(p, niceval, error);
232 break;
233 case PRIO_PGRP:
234 if (who)
235 pgrp = find_vpid(who);
236 else
237 pgrp = task_pgrp(current);
238 do_each_pid_thread(pgrp, PIDTYPE_PGID, p) {
239 error = set_one_prio(p, niceval, error);
240 } while_each_pid_thread(pgrp, PIDTYPE_PGID, p);
241 break;
242 case PRIO_USER:
243 uid = make_kuid(cred->user_ns, who);
244 user = cred->user;
245 if (!who)
246 uid = cred->uid;
247 else if (!uid_eq(uid, cred->uid)) {
248 user = find_user(uid);
249 if (!user)
250 goto out_unlock; /* No processes for this user */
251 }
252 do_each_thread(g, p) {
253 if (uid_eq(task_uid(p), uid) && task_pid_vnr(p))
254 error = set_one_prio(p, niceval, error);
255 } while_each_thread(g, p);
256 if (!uid_eq(uid, cred->uid))
257 free_uid(user); /* For find_user() */
258 break;
259 }
260 out_unlock:
261 read_unlock(&tasklist_lock);
262 rcu_read_unlock();
263 out:
264 return error;
265 }
266
267 SYSCALL_DEFINE3(setpriority, int, which, int, who, int, niceval)
268 {
269 return ksys_setpriority(which, who, niceval);
270 }
271
272 /*
273 * Ugh. To avoid negative return values, "getpriority()" will
274 * not return the normal nice-value, but a negated value that
275 * has been offset by 20 (ie it returns 40..1 instead of -20..19)
276 * to stay compatible.
277 */
> 278 int ksys_getpriority(int which, int who)
279 {
280 struct task_struct *g, *p;
281 struct user_struct *user;
282 const struct cred *cred = current_cred();
283 long niceval, retval = -ESRCH;
284 struct pid *pgrp;
285 kuid_t uid;
286
287 if (which > PRIO_USER || which < PRIO_PROCESS)
288 return -EINVAL;
289
290 rcu_read_lock();
291 read_lock(&tasklist_lock);
292 switch (which) {
293 case PRIO_PROCESS:
294 if (who)
295 p = find_task_by_vpid(who);
296 else
297 p = current;
298 if (p) {
299 niceval = nice_to_rlimit(task_nice(p));
300 if (niceval > retval)
301 retval = niceval;
302 }
303 break;
304 case PRIO_PGRP:
305 if (who)
306 pgrp = find_vpid(who);
307 else
308 pgrp = task_pgrp(current);
309 do_each_pid_thread(pgrp, PIDTYPE_PGID, p) {
310 niceval = nice_to_rlimit(task_nice(p));
311 if (niceval > retval)
312 retval = niceval;
313 } while_each_pid_thread(pgrp, PIDTYPE_PGID, p);
314 break;
315 case PRIO_USER:
316 uid = make_kuid(cred->user_ns, who);
317 user = cred->user;
318 if (!who)
319 uid = cred->uid;
320 else if (!uid_eq(uid, cred->uid)) {
321 user = find_user(uid);
322 if (!user)
323 goto out_unlock; /* No processes for this user */
324 }
325 do_each_thread(g, p) {
326 if (uid_eq(task_uid(p), uid) && task_pid_vnr(p)) {
327 niceval = nice_to_rlimit(task_nice(p));
328 if (niceval > retval)
329 retval = niceval;
330 }
331 } while_each_thread(g, p);
332 if (!uid_eq(uid, cred->uid))
333 free_uid(user); /* for find_user() */
334 break;
335 }
336 out_unlock:
337 read_unlock(&tasklist_lock);
338 rcu_read_unlock();
339
340 return retval;
341 }
342
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
9 months, 1 week
[android-common:android12-5.10 6769/13830] include/trace/hooks/typec.h:20:1: sparse: sparse: incorrect type in assignment (different address spaces)
by kernel test robot
tree: https://android.googlesource.com/kernel/common android12-5.10
head: 2d6a43c0364d3bb0c5c00b0a32b27f4c7740e004
commit: abbebf1a3e6ab5a14cf34a2fe03dba7e10c2cf2c [6769/13830] ANDROID: usb: typec: tcpci: Migrate restricted vendor hook
config: x86_64-randconfig-s021-20211207 (https://download.01.org/0day-ci/archive/20211212/202112120711.pCFZtRHl-lk...)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.4-dirty
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android12-5.10
git checkout abbebf1a3e6ab5a14cf34a2fe03dba7e10c2cf2c
# save the config file to linux build tree
mkdir build_dir
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/android/ drivers/media/mc/ drivers/media/v4l2-core/ drivers/pci/ kernel/ net/core/ net/ipv4/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
include/trace/hooks/sched.h:199:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:199:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:199:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:203:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:203:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:203:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:207:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:207:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:207:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:211:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:211:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:211:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:215:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:215:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:215:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:219:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:219:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:219:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:235:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:235:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:235:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:239:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:239:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:239:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:244:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:244:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:244:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:249:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:249:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:249:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:263:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:263:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:263:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:271:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:271:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:271:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:274:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:274:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:274:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:277:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:277:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:277:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:281:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:281:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:281:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/cpufreq.h):
include/trace/hooks/cpufreq.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/cpufreq.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/cpufreq.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/mm.h):
include/trace/hooks/mm.h:16:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:16:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:16:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/preemptirq.h):
include/trace/hooks/preemptirq.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:18:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:18:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:18:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:26:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:26:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:26:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/bug.h):
include/trace/hooks/bug.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/bug.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/bug.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/fault.h):
include/trace/hooks/fault.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:27:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:27:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:27:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/traps.h):
include/trace/hooks/traps.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/traps.h:20:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:20:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:20:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/traps.h:24:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:24:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:24:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/typec.h):
>> include/trace/hooks/typec.h:20:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/typec.h:20:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/typec.h:20:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/typec.h:31:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/typec.h:31:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/typec.h:31:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
vim +20 include/trace/hooks/typec.h
15
16 DECLARE_HOOK(android_vh_typec_tcpci_override_toggling,
17 TP_PROTO(struct tcpci *tcpci, struct tcpci_data *data, int *override_toggling),
18 TP_ARGS(tcpci, data, override_toggling));
19
> 20 DECLARE_RESTRICTED_HOOK(android_rvh_typec_tcpci_chk_contaminant,
21 TP_PROTO(struct tcpci *tcpci, struct tcpci_data *data, int *ret),
22 TP_ARGS(tcpci, data, ret), 1);
23
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
9 months, 1 week
[chrome-os:chromeos-5.15 970/2818] drivers/tty/sysrq.c:462:57: error: implicit conversion from 'enum <anonymous>' to 'enum pid_type'
by kernel test robot
tree: https://chromium.googlesource.com/chromiumos/third_party/kernel chromeos-5.15
head: b4852fbf90916fdc2f1e0e282e100f7e0e889d77
commit: 297837590e60714af43864f54661c2410913aaa4 [970/2818] CHROMIUM: sysrq: Added Chrome OS specific 'x' key
config: arm-chromiumos-arm-customedconfig-chrome-os:chromeos-5.15:b4852fbf90916fdc2f1e0e282e100f7e0e889d77 (https://download.01.org/0day-ci/archive/20211212/202112120632.ebpnDry5-lk...)
compiler: arm-linux-gnueabi-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git remote add chrome-os https://chromium.googlesource.com/chromiumos/third_party/kernel
git fetch --no-tags chrome-os chromeos-5.15
git checkout 297837590e60714af43864f54661c2410913aaa4
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arm SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
drivers/tty/sysrq.c: In function 'sysrq_x_cros_signal_process':
>> drivers/tty/sysrq.c:462:57: error: implicit conversion from 'enum <anonymous>' to 'enum pid_type' [-Werror=enum-conversion]
462 | do_send_sig_info(sig, SEND_SIG_PRIV, p, true);
| ^~~~
cc1: all warnings being treated as errors
vim +462 drivers/tty/sysrq.c
442
443 /* send a signal to a process named comm if it has a certain parent */
444 /* if parent is NULL, send to the first matching process */
445 static void sysrq_x_cros_signal_process(char *comm, char *parent, int sig)
446 {
447 struct task_struct *p;
448
449 read_lock(&tasklist_lock);
450 for_each_process(p) {
451 if (p->flags & (PF_KTHREAD | PF_EXITING))
452 continue;
453 if (is_global_init(p))
454 continue;
455 if (strncmp(p->comm, comm, TASK_COMM_LEN))
456 continue;
457 if (parent && strncmp(p->parent->comm, parent, TASK_COMM_LEN))
458 continue;
459
460 printk(KERN_INFO "%s: signal %d %s pid %u tgid %u\n",
461 __func__, sig, comm, p->pid, p->tgid);
> 462 do_send_sig_info(sig, SEND_SIG_PRIV, p, true);
463 }
464 read_unlock(&tasklist_lock);
465 }
466
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
9 months, 1 week
[sashal-stable:pending-5.4 2/2] drivers/pinctrl/pinctrl-amd.c:958:39: error: 'struct amd_gpio' has no member named 'irq'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git pending-5.4
head: 1cfc24b393efef2fed7000bd6109ca72f5bcc55a
commit: 1cfc24b393efef2fed7000bd6109ca72f5bcc55a [2/2] pinctrl: amd: Fix wakeups when IRQ is shared with SCI
config: x86_64-allyesconfig (https://download.01.org/0day-ci/archive/20211212/202112120623.J9RQqJNr-lk...)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
# https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git/c...
git remote add sashal-stable https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git
git fetch --no-tags sashal-stable pending-5.4
git checkout 1cfc24b393efef2fed7000bd6109ca72f5bcc55a
# save the config file to linux build tree
mkdir build_dir
make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/pinctrl/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
drivers/pinctrl/pinctrl-amd.c: In function 'amd_gpio_probe':
>> drivers/pinctrl/pinctrl-amd.c:958:39: error: 'struct amd_gpio' has no member named 'irq'
958 | acpi_register_wakeup_handler(gpio_dev->irq, amd_gpio_check_wake, gpio_dev);
| ^~
vim +958 drivers/pinctrl/pinctrl-amd.c
917
918 gpio_dev->hwbank_num = gpio_dev->gc.ngpio / 64;
919 gpio_dev->groups = kerncz_groups;
920 gpio_dev->ngroups = ARRAY_SIZE(kerncz_groups);
921
922 amd_pinctrl_desc.name = dev_name(&pdev->dev);
923 gpio_dev->pctrl = devm_pinctrl_register(&pdev->dev, &amd_pinctrl_desc,
924 gpio_dev);
925 if (IS_ERR(gpio_dev->pctrl)) {
926 dev_err(&pdev->dev, "Couldn't register pinctrl driver\n");
927 return PTR_ERR(gpio_dev->pctrl);
928 }
929
930 ret = gpiochip_add_data(&gpio_dev->gc, gpio_dev);
931 if (ret)
932 return ret;
933
934 ret = gpiochip_add_pin_range(&gpio_dev->gc, dev_name(&pdev->dev),
935 0, 0, gpio_dev->gc.ngpio);
936 if (ret) {
937 dev_err(&pdev->dev, "Failed to add pin range\n");
938 goto out2;
939 }
940
941 ret = gpiochip_irqchip_add(&gpio_dev->gc,
942 &amd_gpio_irqchip,
943 0,
944 handle_simple_irq,
945 IRQ_TYPE_NONE);
946 if (ret) {
947 dev_err(&pdev->dev, "could not add irqchip\n");
948 ret = -ENODEV;
949 goto out2;
950 }
951
952 ret = devm_request_irq(&pdev->dev, irq_base, amd_gpio_irq_handler,
953 IRQF_SHARED, KBUILD_MODNAME, gpio_dev);
954 if (ret)
955 goto out2;
956
957 platform_set_drvdata(pdev, gpio_dev);
> 958 acpi_register_wakeup_handler(gpio_dev->irq, amd_gpio_check_wake, gpio_dev);
959
960 dev_dbg(&pdev->dev, "amd gpio driver loaded\n");
961 return ret;
962
963 out2:
964 gpiochip_remove(&gpio_dev->gc);
965
966 return ret;
967 }
968
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
9 months, 1 week
[android-common:android12-5.10 6328/13830] include/trace/hooks/traps.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces)
by kernel test robot
tree: https://android.googlesource.com/kernel/common android12-5.10
head: 2d6a43c0364d3bb0c5c00b0a32b27f4c7740e004
commit: 9108e9ba66fe26ed7d896febb70b8afafcc2b70f [6328/13830] ANDROID: arm64: add vendor hooks for unusal abort cases
config: x86_64-randconfig-s021-20211207 (https://download.01.org/0day-ci/archive/20211212/202112120636.bChSSkZs-lk...)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.4-dirty
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android12-5.10
git checkout 9108e9ba66fe26ed7d896febb70b8afafcc2b70f
# save the config file to linux build tree
mkdir build_dir
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/android/ drivers/media/mc/ drivers/media/v4l2-core/ drivers/pci/ kernel/ net/core/ net/ipv4/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
include/trace/hooks/sched.h:175:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:179:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:179:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:179:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:183:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:183:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:183:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:187:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:187:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:187:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:192:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:192:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:192:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:196:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:196:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:196:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:200:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:200:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:200:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:204:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:204:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:204:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:209:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:209:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:209:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:213:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:213:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:213:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:217:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:217:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:217:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:221:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:221:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:221:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:225:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:225:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:225:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:229:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:229:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:229:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:245:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:245:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:245:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:249:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:249:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:249:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:254:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:254:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:254:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:259:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:259:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:259:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:273:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:273:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:273:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/cpufreq.h):
include/trace/hooks/cpufreq.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/cpufreq.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/cpufreq.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/mm.h):
include/trace/hooks/mm.h:16:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:16:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:16:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/preemptirq.h):
include/trace/hooks/preemptirq.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:18:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:18:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:18:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:26:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:26:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:26:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/bug.h):
include/trace/hooks/bug.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/bug.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/bug.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/fault.h):
include/trace/hooks/fault.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:27:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:27:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:27:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/traps.h):
>> include/trace/hooks/traps.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/traps.h:20:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:20:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:20:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/traps.h:24:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:24:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:24:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
vim +15 include/trace/hooks/traps.h
5
6 #if !defined(_TRACE_HOOK_TRAPS_H) || defined(TRACE_HEADER_MULTI_READ)
7 #define _TRACE_HOOK_TRAPS_H
8 #include <linux/tracepoint.h>
9 #include <trace/hooks/vendor_hooks.h>
10 /*
11 * Following tracepoints are not exported in tracefs and provide a
12 * mechanism for vendor modules to hook and extend functionality
13 */
14 struct pt_regs;
> 15 DECLARE_RESTRICTED_HOOK(android_rvh_do_undefinstr,
16 TP_PROTO(struct pt_regs *regs, bool user),
17 TP_ARGS(regs, user),
18 TP_CONDITION(!user));
19
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
9 months, 1 week