Re: [PATCH 05/10] mtd: rawnand: Rename the use_bufpoi variables

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

 



Hi Boris,

Boris Brezillon <boris.brezillon@xxxxxxxxxxxxx> wrote on Sat, 25 Apr
2020 10:44:40 +0200:

> On Fri, 24 Apr 2020 19:36:26 +0200
> Miquel Raynal <miquel.raynal@xxxxxxxxxxx> wrote:
> 
> > Both in nand_do_read_ops() and nand_do_write_ops() there is a boolean
> > called use_bufpoi which is set to true in case of unaligned request or
> > when there is a need for a DMA-able buffer. It basically means "use a
> > bounce buffer".
> > 
> > Depending on the value of use_bufpoi, the bufpoi variable is always
> > used and will either point to the original buffer or to the nand_chip
> > structure "internal data buffer" (this buffer is allocated with
> > kmalloc() on purpose so that it will be DMA-compliant).
> > 
> > In all cases bufpoi is used so the boolean name is misleading. Rename
> > use_bufpoi to be use_bouce_buf to be more accurate.
> > 
> > Signed-off-by: Miquel Raynal <miquel.raynal@xxxxxxxxxxx>  
> 
> Reviewed-by: Boris Brezillon <boris.brezillon@xxxxxxxxxxxxx>
> 
> I wonder if we shouldn't find a better name for bufpoi too. Not sure
> what the poi means here (pointer?). So maybe just rename those into
> read_buf, write_buf (since buf seems to be declared already).

My first patch also renamed bufpoi.

Actually I read it like "buf pointer" and it makes sense and is used
all across nand_base.c so I decided to let it as-is for now.

Thanks,
Miquèl

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/




[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux