]> Pileus Git - ~andy/linux/blobdiff - drivers/staging/iio/dds/ad9834.c
Merge branch 'staging-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh...
[~andy/linux] / drivers / staging / iio / dds / ad9834.c
index 51fda6f6981587c3aade74dd3bf15b5bb7a33c9c..5e67104fea18cb3f94eadbb77d9f9f3e7d8e0afb 100644 (file)
@@ -77,7 +77,7 @@ static ssize_t ad9834_write(struct device *dev,
                goto error_ret;
 
        mutex_lock(&indio_dev->mlock);
-       switch (this_attr->address) {
+       switch ((u32) this_attr->address) {
        case AD9834_REG_FREQ0:
        case AD9834_REG_FREQ1:
                ret = ad9834_write_frequency(st, this_attr->address, val);
@@ -153,7 +153,7 @@ static ssize_t ad9834_store_wavetype(struct device *dev,
 
        mutex_lock(&indio_dev->mlock);
 
-       switch (this_attr->address) {
+       switch ((u32) this_attr->address) {
        case 0:
                if (sysfs_streq(buf, "sine")) {
                        st->control &= ~AD9834_MODE;
@@ -435,11 +435,11 @@ static const struct spi_device_id ad9834_id[] = {
        {"ad9838", ID_AD9838},
        {}
 };
+MODULE_DEVICE_TABLE(spi, ad9834_id);
 
 static struct spi_driver ad9834_driver = {
        .driver = {
                .name   = "ad9834",
-               .bus    = &spi_bus_type,
                .owner  = THIS_MODULE,
        },
        .probe          = ad9834_probe,
@@ -451,4 +451,3 @@ module_spi_driver(ad9834_driver);
 MODULE_AUTHOR("Michael Hennerich <hennerich@blackfin.uclinux.org>");
 MODULE_DESCRIPTION("Analog Devices AD9833/AD9834/AD9837/AD9838 DDS");
 MODULE_LICENSE("GPL v2");
-MODULE_ALIAS("spi:ad9834");