Hi Mercier, FYI, the error/warning still remains. tree: https://android.googlesource.com/kernel/common android12-5.10 head: ac30bb6084661f71225ff2b22cd09df34427b963 commit: 5aec776ef8c9319df4938fa87e8f2df018426960 [21719/21832] BACKPORT: ANDROID: dma-buf: Move sysfs work out of DMA-BUF export path config: i386-randconfig-r002-20221128 compiler: gcc-11 (Debian 11.3.0-8) 11.3.0 reproduce (this is a W=1 build): git remote add android-common https://android.googlesource.com/kernel/common git fetch --no-tags android-common android12-5.10 git checkout 5aec776ef8c9319df4938fa87e8f2df018426960 # save the config file mkdir build_dir && cp config build_dir/.config make W=1 O=build_dir ARCH=i386 SHELL=/bin/bash drivers/ If you fix the issue, kindly add following tag where applicable | Reported-by: kernel test robot All errors (new ones prefixed by >>): drivers/dma-buf/dma-buf-sysfs-stats.c: In function 'sysfs_add_workfn': >> drivers/dma-buf/dma-buf-sysfs-stats.c:142:9: error: static assertion failed: "kobject is smaller than work_struct" 142 | _Static_assert(sizeof(struct kobject) >= sizeof(struct work_struct), | ^~~~~~~~~~~~~~ vim +142 drivers/dma-buf/dma-buf-sysfs-stats.c 138 139 static void sysfs_add_workfn(struct work_struct *work) 140 { 141 /* The ABI would have to change for this to be false, but let's be paranoid. */ > 142 _Static_assert(sizeof(struct kobject) >= sizeof(struct work_struct), 143 "kobject is smaller than work_struct"); 144 145 struct dma_buf_sysfs_entry *sysfs_entry = 146 container_of((struct kobject *)work, struct dma_buf_sysfs_entry, kobj); 147 struct dma_buf *dmabuf = sysfs_entry->dmabuf; 148 149 /* 150 * A dmabuf is ref-counted via its file member. If this handler holds the only 151 * reference to the dmabuf, there is no need for sysfs kobject creation. This is an 152 * optimization and a race; when the reference count drops to 1 immediately after 153 * this check it is not harmful as the sysfs entry will still get cleaned up in 154 * dma_buf_stats_teardown, which won't get called until the final dmabuf reference 155 * is released, and that can't happen until the end of this function. 156 */ 157 if (file_count(dmabuf->file) > 1) { 158 /* 159 * kobject_init_and_add expects kobject to be zero-filled, but we have populated it 160 * to trigger this work function. 161 */ 162 memset(&dmabuf->sysfs_entry->kobj, 0, sizeof(dmabuf->sysfs_entry->kobj)); 163 dmabuf->sysfs_entry->kobj.kset = dma_buf_per_buffer_stats_kset; 164 if (kobject_init_and_add(&dmabuf->sysfs_entry->kobj, &dma_buf_ktype, NULL, 165 "%lu", file_inode(dmabuf->file)->i_ino)) { 166 kobject_put(&dmabuf->sysfs_entry->kobj); 167 dmabuf->sysfs_entry = NULL; 168 } 169 } else { 170 /* 171 * Free the sysfs_entry and reset the pointer so dma_buf_stats_teardown doesn't 172 * attempt to operate on it. 173 */ 174 kfree(dmabuf->sysfs_entry); 175 dmabuf->sysfs_entry = NULL; 176 } 177 dma_buf_put(dmabuf); 178 } 179 -- 0-DAY CI Kernel Test Service https://01.org/lkp