From: Allen Pais <apais@linux.microsoft.com>
To: Michael Ellerman <mpe@ellerman.id.au>
Cc: linux-scsi@vger.kernel.org,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
linuxppc-dev@lists.ozlabs.org, target-devel@vger.kernel.org,
megaraidlinux.pdl@broadcom.com, jejb@linux.ibm.com,
hare@suse.com, martin.petersen@oracle.com,
linuxdrivers@attotech.com, tyreld@linux.ibm.com,
npiggin@gmail.com, christophe.leroy@csgroup.eu,
aneesh.kumar@kernel.org, naveen.n.rao@linux.ibm.com,
artur.paszkiewicz@intel.co, kashyap.desai@broadcom.com,
sumit.saxena@broadcom.com,
shivasharan.srikanteshwara@broadcom.com,
chandrakanth.patil@broadcom.com, jinpu.wang@cloud.ionos.com
Subject: Re: [PATCH] [RFC] scsi: Convert from tasklet to BH workqueue
Date: Fri, 3 May 2024 08:32:54 -0700 [thread overview]
Message-ID: <BA5F645E-7DC6-4737-BCB2-6CD8E2C4471A@linux.microsoft.com> (raw)
In-Reply-To: <87ikzv3b4n.fsf@mail.lhotse>
> On May 2, 2024, at 7:03 PM, Michael Ellerman <mpe@ellerman.id.au> wrote:
>
> Allen Pais <apais@linux.microsoft.com> writes:
>> The only generic interface to execute asynchronously in the BH context is
>> tasklet; however, it's marked deprecated and has some design flaws. To
>> replace tasklets, BH workqueue support was recently added. A BH workqueue
>> behaves similarly to regular workqueues except that the queued work items
>> are executed in the BH context.
>>
>> This patch converts drivers/scsi/* from tasklet to BH workqueue.
>>
>> Based on the work done by Tejun Heo <tj@kernel.org>
>> Branch: https://git.kernel.org/pub/scm/linux/kernel/git/tj/wq.git for-6.10
>>
>> Signed-off-by: Allen Pais <allen.lkml@gmail.com>
>> ---
>> drivers/scsi/aic7xxx/aic7xxx_osm.c | 2 +-
>> drivers/scsi/aic94xx/aic94xx_hwi.c | 14 ++--
>> drivers/scsi/aic94xx/aic94xx_hwi.h | 5 +-
>> drivers/scsi/aic94xx/aic94xx_scb.c | 36 +++++-----
>> drivers/scsi/aic94xx/aic94xx_task.c | 14 ++--
>> drivers/scsi/aic94xx/aic94xx_tmf.c | 34 ++++-----
>> drivers/scsi/esas2r/esas2r.h | 12 ++--
>> drivers/scsi/esas2r/esas2r_init.c | 14 ++--
>> drivers/scsi/esas2r/esas2r_int.c | 18 ++---
>> drivers/scsi/esas2r/esas2r_io.c | 2 +-
>> drivers/scsi/esas2r/esas2r_main.c | 16 ++---
>> drivers/scsi/ibmvscsi/ibmvfc.c | 16 ++---
>> drivers/scsi/ibmvscsi/ibmvfc.h | 3 +-
>> drivers/scsi/ibmvscsi/ibmvscsi.c | 16 ++---
>> drivers/scsi/ibmvscsi/ibmvscsi.h | 3 +-
>> drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.c | 15 ++--
>> drivers/scsi/ibmvscsi_tgt/ibmvscsi_tgt.h | 3 +-
>
> Something there is giving me a build failure (ppc64le_guest_defconfig):
>
> + make -s 'CC=ccache powerpc64le-linux-gnu-gcc' -j 4
> /linux/drivers/scsi/ibmvscsi/ibmvscsi.c: In function 'ibmvscsi_init_crq_queue':
> Error: /linux/drivers/scsi/ibmvscsi/ibmvscsi.c:370:331: error: 'ibmvscsi_work' undeclared (first use in this function)
> /linux/drivers/scsi/ibmvscsi/ibmvscsi.c:370:331: note: each undeclared identifier is reported only once for each function it appears in
> /linux/scripts/Makefile.build:244: recipe for target 'drivers/scsi/ibmvscsi/ibmvscsi.o' failed
> /linux/scripts/Makefile.build:485: recipe for target 'drivers/scsi/ibmvscsi' failed
> /linux/scripts/Makefile.build:485: recipe for target 'drivers/scsi' failed
> /linux/scripts/Makefile.build:485: recipe for target 'drivers' failed
> /linux/drivers/scsi/ibmvscsi/ibmvscsi.c: In function 'ibmvscsi_probe':
> Error: /linux/drivers/scsi/ibmvscsi/ibmvscsi.c:2255:78: error: passing argument 1 of 'kthread_create_on_node' from incompatible pointer type [-Werror=incompatible-pointer-types]
> In file included from /linux/drivers/scsi/ibmvscsi/ibmvscsi.c:56:0:
> /linux/include/linux/kthread.h:11:21: note: expected 'int (*)(void *)' but argument is of type 'int (*)(struct work_struct *)'
> struct task_struct *kthread_create_on_node(int (*threadfn)(void *data),
> ^
> /linux/drivers/scsi/ibmvscsi/ibmvscsi.c: At top level:
> Warning: /linux/drivers/scsi/ibmvscsi/ibmvscsi.c:212:13: warning: 'ibmvscsi_task' defined but not used [-Wunused-function]
> static void ibmvscsi_task(void *data)
> ^
> Warning: cc1: warning: unrecognized command line option '-Wno-shift-negative-value'
> Warning: cc1: warning: unrecognized command line option '-Wno-stringop-overflow'
> cc1: some warnings being treated as errors
> make[6]: *** [drivers/scsi/ibmvscsi/ibmvscsi.o] Error 1
> make[5]: *** [drivers/scsi/ibmvscsi] Error 2
> make[4]: *** [drivers/scsi] Error 2
> make[3]: *** [drivers] Error 2
> make[3]: *** Waiting for unfinished jobs....
>
> Full log here: https://github.com/linuxppc/linux-snowpatch/actions/runs/8930174372/job/24529645923
Thank you for testing it out. Unfortunately, I did not cross-compile it.
Will fix this in v2.
- Allen
>
> Cross compile instructions if you're keen: https://github.com/linuxppc/wiki/wiki/Building-powerpc-kernels
>
> cheers
prev parent reply other threads:[~2024-05-03 15:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-02 20:34 [PATCH 0/1] Convert tasklets to bottom half workqueues Allen Pais
2024-05-02 20:34 ` [PATCH] [RFC] scsi: Convert from tasklet to BH workqueue Allen Pais
2024-05-03 2:03 ` Michael Ellerman
2024-05-03 15:32 ` Allen Pais [this message]
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=BA5F645E-7DC6-4737-BCB2-6CD8E2C4471A@linux.microsoft.com \
--to=apais@linux.microsoft.com \
--cc=aneesh.kumar@kernel.org \
--cc=artur.paszkiewicz@intel.co \
--cc=chandrakanth.patil@broadcom.com \
--cc=christophe.leroy@csgroup.eu \
--cc=hare@suse.com \
--cc=jejb@linux.ibm.com \
--cc=jinpu.wang@cloud.ionos.com \
--cc=kashyap.desai@broadcom.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=linuxdrivers@attotech.com \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=martin.petersen@oracle.com \
--cc=megaraidlinux.pdl@broadcom.com \
--cc=mpe@ellerman.id.au \
--cc=naveen.n.rao@linux.ibm.com \
--cc=npiggin@gmail.com \
--cc=shivasharan.srikanteshwara@broadcom.com \
--cc=sumit.saxena@broadcom.com \
--cc=target-devel@vger.kernel.org \
--cc=tyreld@linux.ibm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox