On Wed, Jun 29, 2011 at 19:12, Scott Jiang wrote:
> +             intf->ppi_control = 0x0002;

these magic numbers really need to be defines.  i'll probably merge
the toolchain/trunk/proc-defs/header-frags/regbits/ppi.h header file
into asm/bfin_ppi.h, then you can replace all of this logic with that.

> +             /* set xfer type */
> +             if (!(params->flags & PPI_FLAG_NO_SYNC))
> +                     intf->ppi_control |= 0x000c;
> +             /* set port cfg */
> +             else if (params->flags & PPI_FLAG_ONE_SYNC)
> +                     intf->ppi_control |= 0x0000;
> +             else if (params->flags & PPI_FLAG_FS2_ASSERT)
> +                     intf->ppi_control |= 0x0030;
> +             else
> +                     intf->ppi_control |= 0x0010;

do we really need to have this abstraction ?  why dont we just let
users program the ppi_control directly via the board config.
-mike
_______________________________________________
Linux-kernel-commits mailing list
[email protected]
https://blackfin.uclinux.org/mailman/listinfo/linux-kernel-commits

Reply via email to