Re: [PATCH 2/2] mtd: lpc32xx_mlc: Adjust to pl08x DMA interface changes

2012-07-13 Thread Alexandre Pereira da Silva
On Thu, Jul 12, 2012 at 9:22 AM, Roland Stigge  wrote:
> This patch adjusts the LPC32xx MLC NAND driver to the new pl08x DMA interface,
> fixing the compile error resulting from changed pl08x structures.
>
> Signed-off-by: Roland Stigge 

Acked-By: Alexandre Pereira da Silva 

> ---
>
> Applies to today's linux-next (integrated lpc32xx-next and dma branches which 
> collide)
>
>  drivers/mtd/nand/lpc32xx_mlc.c |   13 +
>  1 file changed, 1 insertion(+), 12 deletions(-)
>
> diff --git a/drivers/mtd/nand/lpc32xx_mlc.c b/drivers/mtd/nand/lpc32xx_mlc.c
> index 260b2c2..1cf3593 100644
> --- a/drivers/mtd/nand/lpc32xx_mlc.c
> +++ b/drivers/mtd/nand/lpc32xx_mlc.c
> @@ -576,17 +576,6 @@ static void lpc32xx_ecc_enable(struct mtd_info *mtd, int 
> mode)
> /* Always enabled! */
>  }
>
> -static bool lpc32xx_dma_filter(struct dma_chan *chan, void *param)
> -{
> -   struct pl08x_dma_chan *ch =
> -   container_of(chan, struct pl08x_dma_chan, chan);
> -
> -   /* In LPC32xx's PL080 DMA wiring, the MLC NAND DMA signal is #12 */
> -   if (ch->cd->min_signal == 12)
> -   return true;
> -   return false;
> -}
> -
>  static int lpc32xx_dma_setup(struct lpc32xx_nand_host *host)
>  {
> struct mtd_info *mtd = >mtd;
> @@ -594,7 +583,7 @@ static int lpc32xx_dma_setup(struct lpc32xx_nand_host 
> *host)
>
> dma_cap_zero(mask);
> dma_cap_set(DMA_SLAVE, mask);
> -   host->dma_chan = dma_request_channel(mask, lpc32xx_dma_filter, NULL);
> +   host->dma_chan = dma_request_channel(mask, pl08x_filter_id, 
> "nand-mlc");
> if (!host->dma_chan) {
> dev_err(mtd->dev.parent, "Failed to request DMA channel\n");
> return -EBUSY;
> --
> 1.7.10.4
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 2/2] mtd: lpc32xx_mlc: Adjust to pl08x DMA interface changes

2012-07-13 Thread Alexandre Pereira da Silva
On Thu, Jul 12, 2012 at 9:22 AM, Roland Stigge sti...@antcom.de wrote:
 This patch adjusts the LPC32xx MLC NAND driver to the new pl08x DMA interface,
 fixing the compile error resulting from changed pl08x structures.

 Signed-off-by: Roland Stigge sti...@antcom.de

Acked-By: Alexandre Pereira da Silva aletes@gmail.com

 ---

 Applies to today's linux-next (integrated lpc32xx-next and dma branches which 
 collide)

  drivers/mtd/nand/lpc32xx_mlc.c |   13 +
  1 file changed, 1 insertion(+), 12 deletions(-)

 diff --git a/drivers/mtd/nand/lpc32xx_mlc.c b/drivers/mtd/nand/lpc32xx_mlc.c
 index 260b2c2..1cf3593 100644
 --- a/drivers/mtd/nand/lpc32xx_mlc.c
 +++ b/drivers/mtd/nand/lpc32xx_mlc.c
 @@ -576,17 +576,6 @@ static void lpc32xx_ecc_enable(struct mtd_info *mtd, int 
 mode)
 /* Always enabled! */
  }

 -static bool lpc32xx_dma_filter(struct dma_chan *chan, void *param)
 -{
 -   struct pl08x_dma_chan *ch =
 -   container_of(chan, struct pl08x_dma_chan, chan);
 -
 -   /* In LPC32xx's PL080 DMA wiring, the MLC NAND DMA signal is #12 */
 -   if (ch-cd-min_signal == 12)
 -   return true;
 -   return false;
 -}
 -
  static int lpc32xx_dma_setup(struct lpc32xx_nand_host *host)
  {
 struct mtd_info *mtd = host-mtd;
 @@ -594,7 +583,7 @@ static int lpc32xx_dma_setup(struct lpc32xx_nand_host 
 *host)

 dma_cap_zero(mask);
 dma_cap_set(DMA_SLAVE, mask);
 -   host-dma_chan = dma_request_channel(mask, lpc32xx_dma_filter, NULL);
 +   host-dma_chan = dma_request_channel(mask, pl08x_filter_id, 
 nand-mlc);
 if (!host-dma_chan) {
 dev_err(mtd-dev.parent, Failed to request DMA channel\n);
 return -EBUSY;
 --
 1.7.10.4

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 2/2] mtd: lpc32xx_mlc: Adjust to pl08x DMA interface changes

2012-07-12 Thread Roland Stigge
This patch adjusts the LPC32xx MLC NAND driver to the new pl08x DMA interface,
fixing the compile error resulting from changed pl08x structures.

Signed-off-by: Roland Stigge 

---

Applies to today's linux-next (integrated lpc32xx-next and dma branches which 
collide)

 drivers/mtd/nand/lpc32xx_mlc.c |   13 +
 1 file changed, 1 insertion(+), 12 deletions(-)

diff --git a/drivers/mtd/nand/lpc32xx_mlc.c b/drivers/mtd/nand/lpc32xx_mlc.c
index 260b2c2..1cf3593 100644
--- a/drivers/mtd/nand/lpc32xx_mlc.c
+++ b/drivers/mtd/nand/lpc32xx_mlc.c
@@ -576,17 +576,6 @@ static void lpc32xx_ecc_enable(struct mtd_info *mtd, int 
mode)
/* Always enabled! */
 }
 
-static bool lpc32xx_dma_filter(struct dma_chan *chan, void *param)
-{
-   struct pl08x_dma_chan *ch =
-   container_of(chan, struct pl08x_dma_chan, chan);
-
-   /* In LPC32xx's PL080 DMA wiring, the MLC NAND DMA signal is #12 */
-   if (ch->cd->min_signal == 12)
-   return true;
-   return false;
-}
-
 static int lpc32xx_dma_setup(struct lpc32xx_nand_host *host)
 {
struct mtd_info *mtd = >mtd;
@@ -594,7 +583,7 @@ static int lpc32xx_dma_setup(struct lpc32xx_nand_host *host)
 
dma_cap_zero(mask);
dma_cap_set(DMA_SLAVE, mask);
-   host->dma_chan = dma_request_channel(mask, lpc32xx_dma_filter, NULL);
+   host->dma_chan = dma_request_channel(mask, pl08x_filter_id, "nand-mlc");
if (!host->dma_chan) {
dev_err(mtd->dev.parent, "Failed to request DMA channel\n");
return -EBUSY;
-- 
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 2/2] mtd: lpc32xx_mlc: Adjust to pl08x DMA interface changes

2012-07-12 Thread Roland Stigge
This patch adjusts the LPC32xx MLC NAND driver to the new pl08x DMA interface,
fixing the compile error resulting from changed pl08x structures.

Signed-off-by: Roland Stigge sti...@antcom.de

---

Applies to today's linux-next (integrated lpc32xx-next and dma branches which 
collide)

 drivers/mtd/nand/lpc32xx_mlc.c |   13 +
 1 file changed, 1 insertion(+), 12 deletions(-)

diff --git a/drivers/mtd/nand/lpc32xx_mlc.c b/drivers/mtd/nand/lpc32xx_mlc.c
index 260b2c2..1cf3593 100644
--- a/drivers/mtd/nand/lpc32xx_mlc.c
+++ b/drivers/mtd/nand/lpc32xx_mlc.c
@@ -576,17 +576,6 @@ static void lpc32xx_ecc_enable(struct mtd_info *mtd, int 
mode)
/* Always enabled! */
 }
 
-static bool lpc32xx_dma_filter(struct dma_chan *chan, void *param)
-{
-   struct pl08x_dma_chan *ch =
-   container_of(chan, struct pl08x_dma_chan, chan);
-
-   /* In LPC32xx's PL080 DMA wiring, the MLC NAND DMA signal is #12 */
-   if (ch-cd-min_signal == 12)
-   return true;
-   return false;
-}
-
 static int lpc32xx_dma_setup(struct lpc32xx_nand_host *host)
 {
struct mtd_info *mtd = host-mtd;
@@ -594,7 +583,7 @@ static int lpc32xx_dma_setup(struct lpc32xx_nand_host *host)
 
dma_cap_zero(mask);
dma_cap_set(DMA_SLAVE, mask);
-   host-dma_chan = dma_request_channel(mask, lpc32xx_dma_filter, NULL);
+   host-dma_chan = dma_request_channel(mask, pl08x_filter_id, nand-mlc);
if (!host-dma_chan) {
dev_err(mtd-dev.parent, Failed to request DMA channel\n);
return -EBUSY;
-- 
1.7.10.4

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/