Re: [PATCH 1/4] scsi: core: constify pointer to scsi_host_template

From: Christoph Hellwig
Date: Wed Apr 20 2022 - 03:03:32 EST


On Tue, Apr 12, 2022 at 08:57:39AM +0100, John Garry wrote:
> >
>
> The standard flow is:
>
> shost = scsi_host_alloc(sht, )
>
> // modify shost, like
> shost->cmd_per_lun = 5;
>
> scsi_add_host(shost)
>
> Is there some reason for which those two drivers can't follow that?

I think they should. Method tables should not be mutable data.