Re: [PATCH] s390/cio: Remove the invalid condition on IO_SCH_UNREG

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 23.04.21 12:08, Vineeth Vijayan wrote:
> The condition to check the cdev pointer validity on
> css_sch_device_unregister() is a leftover from the 'commit c97cd8c81d4a
> ("s390/cio: Remove pm support from ccw bus driver")'. This could lead to a
> situation, where detaching the disk is not happening completely. Remove

s/disk/device

> this invalid condition in the IO_SCH_UNREG case.
> 
> Fixes: 8cc0dcfdc1c0 ("s390/cio: remove pm support from ccw bus driver")
> Reported-by: Christian Ehrhardt <christian.ehrhardt@xxxxxxxxxxxxx>
> Suggested-by: Christian Ehrhardt <christian.ehrhardt@xxxxxxxxxxxxx>

Thanks! This seems to fix the hot-unplug troubles with qeth devices.

Tested-by: Julian Wiedmann <jwi@xxxxxxxxxxxxx>

> Cc: <stable@xxxxxxxxxxxxxxx>
> Signed-off-by: Vineeth Vijayan <vneethv@xxxxxxxxxxxxx>
> ---
>  drivers/s390/cio/device.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/s390/cio/device.c b/drivers/s390/cio/device.c
> index 3f026021e95e..84f659cafe76 100644
> --- a/drivers/s390/cio/device.c
> +++ b/drivers/s390/cio/device.c
> @@ -1532,8 +1532,7 @@ static int io_subchannel_sch_event(struct subchannel *sch, int process)
>  	switch (action) {
>  	case IO_SCH_ORPH_UNREG:
>  	case IO_SCH_UNREG:
> -		if (!cdev)
> -			css_sch_device_unregister(sch);
> +		css_sch_device_unregister(sch);
>  		break;
>  	case IO_SCH_ORPH_ATTACH:
>  	case IO_SCH_UNREG_ATTACH:
> 




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Kernel Development]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Info]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Linux Media]     [Device Mapper]

  Powered by Linux