From: kernel test robot <lkp@intel.com>
To: jasperwang@tencent.com, kaixuxia@tencent.com,
frankjpliu@tencent.com, kasong@tencent.com,
sagazchen@tencent.com, kernelxing@tencent.com,
aurelianliu@tencent.com, jason.zeng@intel.com,
wu.zheng@intel.com, yingbao.jia@intel.com, pei.p.jia@intel.com
Cc: oe-kbuild-all@lists.linux.dev
Subject: drivers/crypto/hisilicon/uacce/uacce.c:61: warning: Function parameter or member 'dev' not described in 'dev_to_uacce'
Date: Thu, 22 Feb 2024 00:57:59 +0800 [thread overview]
Message-ID: <202402220040.ASuMNilo-lkp@intel.com> (raw)
tree: https://gitee.com/OpenCloudOS/OpenCloudOS-Kernel.git linux-5.4/lts/5.4.119-20.0009
head: 3bf5c3f6e32e9cfe13f09bac3ae93b8e39d472c1
commit: 7274937282a3c591eb292c7bf267b25abf4d4a52 driver: update hisilicon hardware crypto engine
date: 1 year, 1 month ago
config: arm64-randconfig-002-20240221 (https://download.01.org/0day-ci/archive/20240222/202402220040.ASuMNilo-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240222/202402220040.ASuMNilo-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202402220040.ASuMNilo-lkp@intel.com/
All warnings (new ones prefixed by >>):
drivers/crypto/hisilicon/uacce/uacce.c: In function 'numa_distance_show':
>> drivers/crypto/hisilicon/uacce/uacce.c:1027:23: warning: unused variable 'uacce' [-Wunused-variable]
1027 | struct uacce *uacce = UACCE_FROM_CDEV_ATTR(dev);
| ^~~~~
drivers/crypto/hisilicon/uacce/uacce.c: In function 'node_id_show':
drivers/crypto/hisilicon/uacce/uacce.c:1041:23: warning: unused variable 'uacce' [-Wunused-variable]
1041 | struct uacce *uacce = UACCE_FROM_CDEV_ATTR(dev);
| ^~~~~
--
>> drivers/crypto/hisilicon/uacce/uacce.c:61: warning: Function parameter or member 'dev' not described in 'dev_to_uacce'
>> drivers/crypto/hisilicon/uacce/uacce.c:82: warning: Function parameter or member 'uacce' not described in 'uacce_hw_err_isolate'
>> drivers/crypto/hisilicon/uacce/uacce.c:137: warning: Function parameter or member 'q' not described in 'uacce_wake_up'
vim +61 drivers/crypto/hisilicon/uacce/uacce.c
55
56 /**
57 * dev_to_uacce - Get structure uacce from its device
58 * @dev the device
59 */
60 struct uacce *dev_to_uacce(struct device *dev)
> 61 {
62 struct device **tdev = &dev;
63 int ret;
64
65 ret = class_for_each_device(uacce_class, NULL, tdev, cdev_get);
66 if (ret) {
67 dev = *tdev;
68 return UACCE_FROM_CDEV_ATTR(dev);
69 }
70 return NULL;
71 }
72 EXPORT_SYMBOL_GPL(dev_to_uacce);
73
74 /**
75 * uacce_hw_err_isolate - Try to isolate the uacce device with its VFs
76 * according to user's configuration of isolation strategy. Warning: this
77 * API should be called while there is no user on the device, or the users
78 * on this device are suspended by slot resetting preparation of PCI AER.
79 * @uacce the uacce device
80 */
81 int uacce_hw_err_isolate(struct uacce *uacce)
> 82 {
83 struct uacce_err_isolate *isolate = uacce->isolate;
84 struct uacce_hw_err *err, *tmp, *hw_err;
85 u32 count = 0;
86
87 #define SECONDS_PER_HOUR 3600
88
89 /* all the hw errs are processed by PF driver */
90 if (uacce->is_vf || atomic_read(&isolate->is_isolate) ||
91 !isolate->hw_err_isolate_hz)
92 return 0;
93
94 hw_err = kzalloc(sizeof(*hw_err), GFP_ATOMIC);
95 if (!hw_err)
96 return -ENOMEM;
97 hw_err->tick_stamp = jiffies;
98 list_for_each_entry_safe(err, tmp, &isolate->hw_errs, list) {
99 if ((hw_err->tick_stamp - err->tick_stamp) / HZ >
100 SECONDS_PER_HOUR) {
101 list_del(&err->list);
102 kfree(err);
103 } else {
104 count++;
105 }
106 }
107 list_add(&hw_err->list, &isolate->hw_errs);
108
109 if (count >= isolate->hw_err_isolate_hz)
110 atomic_set(&isolate->is_isolate, 1);
111
112 return 0;
113 }
114 EXPORT_SYMBOL_GPL(uacce_hw_err_isolate);
115
116 static void uacce_hw_err_destroy(struct uacce *uacce)
117 {
118 struct uacce_hw_err *err, *tmp;
119
120 list_for_each_entry_safe(err, tmp, &uacce->isolate_data.hw_errs, list) {
121 list_del(&err->list);
122 kfree(err);
123 }
124 }
125
126 const char *uacce_qfrt_str(struct uacce_qfile_region *qfr)
127 {
128 return qfrt_str[qfr->type];
129 }
130 EXPORT_SYMBOL_GPL(uacce_qfrt_str);
131
132 /**
133 * uacce_wake_up - Wake up the process who is waiting this queue
134 * @q the accelerator queue to wake up
135 */
136 void uacce_wake_up(struct uacce_queue *q)
> 137 {
138 dev_dbg(&q->uacce->dev, "wake up\n");
139 wake_up_interruptible(&q->wait);
140 }
141 EXPORT_SYMBOL_GPL(uacce_wake_up);
142
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2024-02-21 17:00 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=202402220040.ASuMNilo-lkp@intel.com \
--to=lkp@intel.com \
--cc=aurelianliu@tencent.com \
--cc=frankjpliu@tencent.com \
--cc=jason.zeng@intel.com \
--cc=jasperwang@tencent.com \
--cc=kaixuxia@tencent.com \
--cc=kasong@tencent.com \
--cc=kernelxing@tencent.com \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=pei.p.jia@intel.com \
--cc=sagazchen@tencent.com \
--cc=wu.zheng@intel.com \
--cc=yingbao.jia@intel.com \
/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.