Thread (4 messages) flat view 4 messages, 3 authors, 1d ago

Re: [PATCH v2] scsi: core: Drop Scsi_Host.default_lock

From: Damien Le Moal <dlemoal@kernel.org>
Date: 2026-08-06 16:30:38
Also in: linux-ide, linux-s390, linux-scsi, linux-usb, lkml

On 2026/08/06 4:39, John Garry wrote:
From: John Garry <redacted>

Back in the 2.6.xx days, it was possible to for low-level drivers to set
s/to for/for
the shost lock pointer. That is why there is a default lock and a pointer
to the shost lock.

However, support for this has long been removed, so drop
Scsi_Host.default_lock and make Scsi_Host.host_lock as the actual lock.

Getting the address of embedded host_lock structure just requires adding
a fixed offset value to the shost pointer. However, getting the value of
the host_lock pointer requires loading from a fixed offset to the shost
pointer. The latter should be very slightly slower, which is relevant as
this lock is used a lot throughout the core code and drivers.

Signed-off-by: John Garry <john.g.garry@oracle.com>
For the ata bits,

Acked-by: Damien Le Moal <dlemoal@kernel.org>

-- 
Damien Le Moal
Western Digital Research
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help