[alsa-devel] [patch 5/9] S3C: Split s3c2412-i2s.c into core and SoC specific parts

Mark Brown broonie at sirena.org.uk
Wed Mar 4 20:52:36 CET 2009


On Wed, Mar 04, 2009 at 12:49:30AM +0000, Ben Dooks wrote:

I'll apply this, just a few comments in passing (I'll probably fix these
up myself).

> The S3C2412 I2S (IIS) interface is replicated on further Samsung SoC
> parts in a broadly compatible way, so split the common code out into
> a core called s3c-i2s-v2.[ch] so that the newer SoCs such as the
> S3C6410 can make use of it.

> As such, all the original s3c2412 functions are currently being left
> with their original names, and will be renamed later in the series.

This does a bit more than the patch description says - it also adds bits
of code for S3C64xx.

> +#if S3C2412_I2S_DEBUG
> +#define DBG(x...) printk(KERN_INFO x)
> +#else
> +#define DBG(x...) do { } while (0)
> +#endif

This should be pr_dbg() (the original file had that fixed).

> +#define bit_set(v, b) (((v) & (b)) ? 1 : 0)

This feels like it should be in some standard header but it isn't.  Ho
hum.

> +	default:
> +		DBG("unknwon master/slave format\n");
> +		return -EINVAL;
> +	}

Should be an unconditional error message.

> +	default:
> +		DBG("Unknown data format\n");
> +		return -EINVAL;
> +	}

Ditto.


More information about the Alsa-devel mailing list