]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/bluetooth/btmrvl_debugfs.c
ARM: mm: proc-arm920: Use the new processor struct macros
[karo-tx-linux.git] / drivers / bluetooth / btmrvl_debugfs.c
index 54739b08c3083d413c70981fc0f0ca095cec0716..8ecf4c6c28740243979920dd98ea7bdc638e5172 100644 (file)
@@ -64,6 +64,8 @@ static ssize_t btmrvl_hscfgcmd_write(struct file *file,
                return -EFAULT;
 
        ret = strict_strtol(buf, 10, &result);
+       if (ret)
+               return ret;
 
        priv->btmrvl_dev.hscfgcmd = result;
 
@@ -92,6 +94,7 @@ static const struct file_operations btmrvl_hscfgcmd_fops = {
        .read   = btmrvl_hscfgcmd_read,
        .write  = btmrvl_hscfgcmd_write,
        .open   = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 static ssize_t btmrvl_psmode_write(struct file *file, const char __user *ubuf,
@@ -107,6 +110,8 @@ static ssize_t btmrvl_psmode_write(struct file *file, const char __user *ubuf,
                return -EFAULT;
 
        ret = strict_strtol(buf, 10, &result);
+       if (ret)
+               return ret;
 
        priv->btmrvl_dev.psmode = result;
 
@@ -130,6 +135,7 @@ static const struct file_operations btmrvl_psmode_fops = {
        .read   = btmrvl_psmode_read,
        .write  = btmrvl_psmode_write,
        .open   = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 static ssize_t btmrvl_pscmd_write(struct file *file, const char __user *ubuf,
@@ -145,6 +151,8 @@ static ssize_t btmrvl_pscmd_write(struct file *file, const char __user *ubuf,
                return -EFAULT;
 
        ret = strict_strtol(buf, 10, &result);
+       if (ret)
+               return ret;
 
        priv->btmrvl_dev.pscmd = result;
 
@@ -173,6 +181,7 @@ static const struct file_operations btmrvl_pscmd_fops = {
        .read = btmrvl_pscmd_read,
        .write = btmrvl_pscmd_write,
        .open = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 static ssize_t btmrvl_gpiogap_write(struct file *file, const char __user *ubuf,
@@ -188,6 +197,8 @@ static ssize_t btmrvl_gpiogap_write(struct file *file, const char __user *ubuf,
                return -EFAULT;
 
        ret = strict_strtol(buf, 16, &result);
+       if (ret)
+               return ret;
 
        priv->btmrvl_dev.gpio_gap = result;
 
@@ -211,6 +222,7 @@ static const struct file_operations btmrvl_gpiogap_fops = {
        .read   = btmrvl_gpiogap_read,
        .write  = btmrvl_gpiogap_write,
        .open   = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 static ssize_t btmrvl_hscmd_write(struct file *file, const char __user *ubuf,
@@ -226,6 +238,8 @@ static ssize_t btmrvl_hscmd_write(struct file *file, const char __user *ubuf,
                return -EFAULT;
 
        ret = strict_strtol(buf, 10, &result);
+       if (ret)
+               return ret;
 
        priv->btmrvl_dev.hscmd = result;
        if (priv->btmrvl_dev.hscmd) {
@@ -252,6 +266,7 @@ static const struct file_operations btmrvl_hscmd_fops = {
        .read   = btmrvl_hscmd_read,
        .write  = btmrvl_hscmd_write,
        .open   = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 static ssize_t btmrvl_hsmode_write(struct file *file, const char __user *ubuf,
@@ -267,6 +282,8 @@ static ssize_t btmrvl_hsmode_write(struct file *file, const char __user *ubuf,
                return -EFAULT;
 
        ret = strict_strtol(buf, 10, &result);
+       if (ret)
+               return ret;
 
        priv->btmrvl_dev.hsmode = result;
 
@@ -289,6 +306,7 @@ static const struct file_operations btmrvl_hsmode_fops = {
        .read   = btmrvl_hsmode_read,
        .write  = btmrvl_hsmode_write,
        .open   = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 static ssize_t btmrvl_curpsmode_read(struct file *file, char __user *userbuf,
@@ -306,6 +324,7 @@ static ssize_t btmrvl_curpsmode_read(struct file *file, char __user *userbuf,
 static const struct file_operations btmrvl_curpsmode_fops = {
        .read   = btmrvl_curpsmode_read,
        .open   = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 static ssize_t btmrvl_psstate_read(struct file *file, char __user * userbuf,
@@ -323,6 +342,7 @@ static ssize_t btmrvl_psstate_read(struct file *file, char __user * userbuf,
 static const struct file_operations btmrvl_psstate_fops = {
        .read   = btmrvl_psstate_read,
        .open   = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 static ssize_t btmrvl_hsstate_read(struct file *file, char __user *userbuf,
@@ -340,6 +360,7 @@ static ssize_t btmrvl_hsstate_read(struct file *file, char __user *userbuf,
 static const struct file_operations btmrvl_hsstate_fops = {
        .read   = btmrvl_hsstate_read,
        .open   = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 static ssize_t btmrvl_txdnldready_read(struct file *file, char __user *userbuf,
@@ -358,6 +379,7 @@ static ssize_t btmrvl_txdnldready_read(struct file *file, char __user *userbuf,
 static const struct file_operations btmrvl_txdnldready_fops = {
        .read   = btmrvl_txdnldready_read,
        .open   = btmrvl_open_generic,
+       .llseek = default_llseek,
 };
 
 void btmrvl_debugfs_init(struct hci_dev *hdev)