Re: [PATCH 09/16] ublk: pass 'const struct ublk_io *' to ublk_[un]map_io()

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

 



On Wed, Jul 2, 2025 at 12:04 AM Ming Lei <ming.lei@xxxxxxxxxx> wrote:
>
> Pass 'const struct ublk_io *' to ublk_[un]map_io() since just io->addr
> and io->res are read in the two helpers.
>
> Signed-off-by: Ming Lei <ming.lei@xxxxxxxxxx>

Reviewed-by: Caleb Sander Mateos <csander@xxxxxxxxxxxxxxx>

> ---
>  drivers/block/ublk_drv.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/block/ublk_drv.c b/drivers/block/ublk_drv.c
> index 13c6b1e0e1ef..3934254f7b99 100644
> --- a/drivers/block/ublk_drv.c
> +++ b/drivers/block/ublk_drv.c
> @@ -993,7 +993,7 @@ static inline bool ublk_need_unmap_req(const struct request *req)
>  }
>
>  static int ublk_map_io(const struct ublk_queue *ubq, const struct request *req,
> -               struct ublk_io *io)
> +                      const struct ublk_io *io)
>  {
>         const unsigned int rq_bytes = blk_rq_bytes(req);
>
> @@ -1017,7 +1017,7 @@ static int ublk_map_io(const struct ublk_queue *ubq, const struct request *req,
>
>  static int ublk_unmap_io(const struct ublk_queue *ubq,
>                 const struct request *req,
> -               struct ublk_io *io)
> +               const struct ublk_io *io)
>  {
>         const unsigned int rq_bytes = blk_rq_bytes(req);
>
> --
> 2.47.0
>





[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux