From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [xlnx:master 371/551] include/linux/sysfs.h:55:8: error: 'struct device_attribute' has no member named 'key'
Date: Fri, 02 Jul 2021 10:11:01 +0800 [thread overview]
Message-ID: <202107021046.AF8PMyro-lkp@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 4017 bytes --]
Hi Nishad,
FYI, the error/warning still remains.
tree: https://github.com/Xilinx/linux-xlnx master
head: 190ba47825b71dd7abeca27b890f1dd5bd5eb781
commit: 12a05be804864f46ccaeccdcf806fe68aa489099 [371/551] misc: xilinx-ai-engine: Create sysfs device attribute framework
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.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/Xilinx/linux-xlnx/commit/12a05be804864f46ccaeccdcf806fe68aa489099
git remote add xlnx https://github.com/Xilinx/linux-xlnx
git fetch --no-tags xlnx master
git checkout 12a05be804864f46ccaeccdcf806fe68aa489099
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross O=build_dir ARCH=arm64 SHELL=/bin/bash drivers/misc/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
In file included from include/linux/kobject.h:20,
from include/linux/cdev.h:5,
from drivers/misc/xilinx-ai-engine/ai-engine-internal.h:14,
from drivers/misc/xilinx-ai-engine/ai-engine-sysfs.c:7:
drivers/misc/xilinx-ai-engine/ai-engine-sysfs.c: In function 'aie_sysfs_create_dev_attr':
>> include/linux/sysfs.h:55:8: error: 'struct device_attribute' has no member named 'key'
55 | (attr)->key = &__key; \
| ^~
drivers/misc/xilinx-ai-engine/ai-engine-sysfs.c:25:2: note: in expansion of macro 'sysfs_attr_init'
25 | sysfs_attr_init(node);
| ^~~~~~~~~~~~~~~
vim +55 include/linux/sysfs.h
^1da177e4c3f41 Linus Torvalds 2005-04-16 39
35960258ed388c Eric W. Biederman 2010-02-12 40 /**
35960258ed388c Eric W. Biederman 2010-02-12 41 * sysfs_attr_init - initialize a dynamically allocated sysfs attribute
35960258ed388c Eric W. Biederman 2010-02-12 42 * @attr: struct attribute to initialize
35960258ed388c Eric W. Biederman 2010-02-12 43 *
35960258ed388c Eric W. Biederman 2010-02-12 44 * Initialize a dynamically allocated struct attribute so we can
35960258ed388c Eric W. Biederman 2010-02-12 45 * make lockdep happy. This is a new requirement for attributes
35960258ed388c Eric W. Biederman 2010-02-12 46 * and initially this is only needed when lockdep is enabled.
35960258ed388c Eric W. Biederman 2010-02-12 47 * Lockdep gives a nice error when your attribute is added to
35960258ed388c Eric W. Biederman 2010-02-12 48 * sysfs if you don't have this.
35960258ed388c Eric W. Biederman 2010-02-12 49 */
6992f5334995af Eric W. Biederman 2010-02-11 50 #ifdef CONFIG_DEBUG_LOCK_ALLOC
6992f5334995af Eric W. Biederman 2010-02-11 51 #define sysfs_attr_init(attr) \
6992f5334995af Eric W. Biederman 2010-02-11 52 do { \
6992f5334995af Eric W. Biederman 2010-02-11 53 static struct lock_class_key __key; \
6992f5334995af Eric W. Biederman 2010-02-11 54 \
6992f5334995af Eric W. Biederman 2010-02-11 @55 (attr)->key = &__key; \
6992f5334995af Eric W. Biederman 2010-02-11 56 } while (0)
6992f5334995af Eric W. Biederman 2010-02-11 57 #else
6992f5334995af Eric W. Biederman 2010-02-11 58 #define sysfs_attr_init(attr) do {} while (0)
6992f5334995af Eric W. Biederman 2010-02-11 59 #endif
6992f5334995af Eric W. Biederman 2010-02-11 60
:::::: The code at line 55 was first introduced by commit
:::::: 6992f5334995af474c2b58d010d08bc597f0f2fe sysfs: Use one lockdep class per sysfs attribute.
:::::: TO: Eric W. Biederman <ebiederm@xmission.com>
:::::: CC: Greg Kroah-Hartman <gregkh@suse.de>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 76045 bytes --]
reply other threads:[~2021-07-02 2:11 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202107021046.AF8PMyro-lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.