tree:
https://github.com/bvanassche/linux scsi-remove-request-pointer
head: 436d8cac8bb5ef646ac94ec9b908804dfd651f33
commit: 436d8cac8bb5ef646ac94ec9b908804dfd651f33 [50/50] core: Remove the request member
from struct scsi_cmnd
config: i386-randconfig-c001-20210522 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
#
https://github.com/bvanassche/linux/commit/436d8cac8bb5ef646ac94ec9b90880...
git remote add bvanassche
https://github.com/bvanassche/linux
git fetch --no-tags bvanassche scsi-remove-request-pointer
git checkout 436d8cac8bb5ef646ac94ec9b908804dfd651f33
# save the attached .config to linux build tree
make W=1 ARCH=i386
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/scsi/aha1542.c: In function 'aha1542_test_port':
drivers/scsi/aha1542.c:209:5: warning: variable 'inquiry_result' set but not
used [-Wunused-but-set-variable]
209 | u8 inquiry_result[4];
| ^~~~~~~~~~~~~~
In file included from include/scsi/scsi_cmnd.h:6,
from drivers/scsi/aha1542.c:23:
drivers/scsi/aha1542.c: In function 'aha1542_free_cmd':
> drivers/scsi/aha1542.c:269:30: error: 'struct scsi_cmnd'
has no member named 'request'
269 | rq_for_each_segment(bv,
cmd->request, iter) {
| ^~
include/linux/blkdev.h:876:7: note: in definition of macro '__rq_for_each_bio'
876 | if ((rq->bio)) \
| ^~
drivers/scsi/aha1542.c:269:3: note: in expansion of macro
'rq_for_each_segment'
269 | rq_for_each_segment(bv, cmd->request, iter) {
| ^~~~~~~~~~~~~~~~~~~
> drivers/scsi/aha1542.c:269:30: error: 'struct scsi_cmnd'
has no member named 'request'
269 | rq_for_each_segment(bv,
cmd->request, iter) {
| ^~
include/linux/blkdev.h:877:16: note: in definition of macro
'__rq_for_each_bio'
877 | for (_bio = (rq)->bio; _bio; _bio = _bio->bi_next)
| ^~
drivers/scsi/aha1542.c:269:3: note: in expansion of macro
'rq_for_each_segment'
269 | rq_for_each_segment(bv, cmd->request, iter) {
| ^~~~~~~~~~~~~~~~~~~
drivers/scsi/aha1542.c: In function 'aha1542_queuecommand':
drivers/scsi/aha1542.c:454:30: error: 'struct scsi_cmnd' has no member named
'request'
454 | rq_for_each_segment(bv, cmd->request, iter) {
| ^~
include/linux/blkdev.h:876:7: note: in definition of macro '__rq_for_each_bio'
876 | if ((rq->bio)) \
| ^~
drivers/scsi/aha1542.c:454:3: note: in expansion of macro
'rq_for_each_segment'
454 | rq_for_each_segment(bv, cmd->request, iter) {
| ^~~~~~~~~~~~~~~~~~~
drivers/scsi/aha1542.c:454:30: error: 'struct scsi_cmnd' has no member named
'request'
454 | rq_for_each_segment(bv, cmd->request, iter) {
| ^~
include/linux/blkdev.h:877:16: note: in definition of macro
'__rq_for_each_bio'
877 | for (_bio = (rq)->bio; _bio; _bio = _bio->bi_next)
| ^~
drivers/scsi/aha1542.c:454:3: note: in expansion of macro
'rq_for_each_segment'
454 | rq_for_each_segment(bv, cmd->request, iter) {
| ^~~~~~~~~~~~~~~~~~~
vim +269 drivers/scsi/aha1542.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 259
1794ef2b150dd5 Christoph Hellwig 2018-11-10 260 static void aha1542_free_cmd(struct
scsi_cmnd *cmd)
1794ef2b150dd5 Christoph Hellwig 2018-11-10 261 {
1794ef2b150dd5 Christoph Hellwig 2018-11-10 262 struct aha1542_cmd *acmd =
scsi_cmd_priv(cmd);
1794ef2b150dd5 Christoph Hellwig 2018-11-10 263
2f2fef022c3e7a Christoph Hellwig 2021-03-31 264 if (cmd->sc_data_direction ==
DMA_FROM_DEVICE) {
2f2fef022c3e7a Christoph Hellwig 2021-03-31 265 void *buf = acmd->data_buffer;
2f2fef022c3e7a Christoph Hellwig 2021-03-31 266 struct req_iterator iter;
2f2fef022c3e7a Christoph Hellwig 2021-03-31 267 struct bio_vec bv;
2f2fef022c3e7a Christoph Hellwig 2021-03-31 268
2f2fef022c3e7a Christoph Hellwig 2021-03-31 @269 rq_for_each_segment(bv,
cmd->request, iter) {
2f2fef022c3e7a Christoph Hellwig 2021-03-31 270 memcpy_to_page(bv.bv_page,
bv.bv_offset, buf,
2f2fef022c3e7a Christoph Hellwig 2021-03-31 271 bv.bv_len);
2f2fef022c3e7a Christoph Hellwig 2021-03-31 272 buf += bv.bv_len;
2f2fef022c3e7a Christoph Hellwig 2021-03-31 273 }
1794ef2b150dd5 Christoph Hellwig 2018-11-10 274 }
1794ef2b150dd5 Christoph Hellwig 2018-11-10 275
1794ef2b150dd5 Christoph Hellwig 2018-11-10 276 scsi_dma_unmap(cmd);
1794ef2b150dd5 Christoph Hellwig 2018-11-10 277 }
1794ef2b150dd5 Christoph Hellwig 2018-11-10 278
:::::: The code at line 269 was first introduced by commit
:::::: 2f2fef022c3e7a29680cb5cb45c460d0ae786d05 aha1542: use a local bounce buffer
:::::: TO: Christoph Hellwig <hch(a)lst.de>
:::::: CC: Jens Axboe <axboe(a)kernel.dk>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org