Re: [PATCH v5 3/3] spi: airoha: add SPI-NAND Flash controller driver

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

 



On Mon, Apr 29, 2024 at 11:13 AM Lorenzo Bianconi <lorenzo@xxxxxxxxxx> wrote:
>
> Introduce support for SPI-NAND driver of the Airoha NAND Flash Interface
> found on Airoha ARM SoCs.

FWIW,
Reviewed-by: Andy Shevchenko <andy@xxxxxxxxxx>

...

> +static void airoha_snand_cleanup(struct spi_device *spi)
> +{
> +       struct airoha_snand_dev *as_dev = spi_get_ctldata(spi);

> +       struct airoha_snand_ctrl *as_ctrl;
> +
> +       as_ctrl = spi_controller_get_devdata(spi->controller);

You may do it on one line above (the same way as for as_dev).
Ditto for other similar cases around.

> +       dma_unmap_single(as_ctrl->dev, as_dev->dma_addr,
> +                        as_dev->buf_len, DMA_BIDIRECTIONAL);
> +       spi_set_ctldata(spi, NULL);
> +}

...

> +static const struct of_device_id airoha_snand_ids[] = {
> +       { .compatible   = "airoha,en7581-snand" },
> +       { /* sentinel */ }
> +};
> +MODULE_DEVICE_TABLE(of, airoha_snand_ids);

No need to keep this block here, the first user is below the ->probe().

-- 
With Best Regards,
Andy Shevchenko





[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux