lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220223115444.wj24a2vvtjc2zexv@ti.com>
Date:   Wed, 23 Feb 2022 17:24:44 +0530
From:   Pratyush Yadav <p.yadav@...com>
To:     Michael Walle <michael@...le.cc>
CC:     <linux-mtd@...ts.infradead.org>, <linux-kernel@...r.kernel.org>,
        Tudor Ambarus <tudor.ambarus@...rochip.com>,
        Miquel Raynal <miquel.raynal@...tlin.com>,
        Richard Weinberger <richard@....at>,
        Vignesh Raghavendra <vigneshr@...com>,
        <yaliang.wang@...driver.com>
Subject: Re: [PATCH v4 26/32] mtd: spi-nor: micron-st: rename vendor specific
 functions and defines

On 21/02/22 01:08PM, Michael Walle wrote:
> Drop the generic spi_nor prefix for all the micron-st functions.
> 
> Signed-off-by: Michael Walle <michael@...le.cc>
> ---
>  drivers/mtd/spi-nor/micron-st.c | 20 ++++++++++----------
>  1 file changed, 10 insertions(+), 10 deletions(-)
> 
> diff --git a/drivers/mtd/spi-nor/micron-st.c b/drivers/mtd/spi-nor/micron-st.c
> index f693f8720541..de450495e1ab 100644
> --- a/drivers/mtd/spi-nor/micron-st.c
> +++ b/drivers/mtd/spi-nor/micron-st.c
> @@ -309,7 +309,7 @@ static int micron_st_nor_set_4byte_addr_mode(struct spi_nor *nor, bool enable)
>  }
>  
>  /**
> - * spi_nor_read_fsr() - Read the Flag Status Register.
> + * micron_st_nor_read_fsr() - Read the Flag Status Register.
>   * @nor:	pointer to 'struct spi_nor'
>   * @fsr:	pointer to a DMA-able buffer where the value of the
>   *              Flag Status Register will be written. Should be at least 2
> @@ -317,7 +317,7 @@ static int micron_st_nor_set_4byte_addr_mode(struct spi_nor *nor, bool enable)
>   *
>   * Return: 0 on success, -errno otherwise.
>   */
> -static int spi_nor_read_fsr(struct spi_nor *nor, u8 *fsr)
> +static int micron_st_nor_read_fsr(struct spi_nor *nor, u8 *fsr)
>  {
>  	int ret;
>  
> @@ -353,10 +353,10 @@ static int spi_nor_read_fsr(struct spi_nor *nor, u8 *fsr)
>  }
>  
>  /**
> - * spi_nor_clear_fsr() - Clear the Flag Status Register.
> + * micron_st_nor_clear_fsr() - Clear the Flag Status Register.
>   * @nor:	pointer to 'struct spi_nor'.
>   */
> -static void spi_nor_clear_fsr(struct spi_nor *nor)
> +static void micron_st_nor_clear_fsr(struct spi_nor *nor)
>  {
>  	int ret;
>  
> @@ -380,13 +380,13 @@ static void spi_nor_clear_fsr(struct spi_nor *nor)
>  }
>  
>  /**
> - * spi_nor_fsr_ready() - Query the Flag Status Register to see if the flash is
> - * ready for new commands.
> + * micron_st_nor_fsr_ready() - Query the Flag Status Register to see if the
> + * flash is ready for new commands.

This is misleading. This function doesn't only query the FSR, but the SR 
as well. I think this should be renamed to micron_st_nor_ready(), and 
documentation updated to reflect that it checks for SR, and then FSR as 
well if the flag is specified.

>   * @nor:	pointer to 'struct spi_nor'.
>   *
>   * Return: 1 if ready, 0 if not ready, -errno on errors.
>   */
> -static int spi_nor_fsr_ready(struct spi_nor *nor)
> +static int micron_st_nor_fsr_ready(struct spi_nor *nor)
>  {
>  	int sr_ready, ret;

-- 
Regards,
Pratyush Yadav
Texas Instruments Inc.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ