[ATM] suni: cast arg properly in SONET_SETFRAMING
authorAlexey Dobriyan <adobriyan@gmail.com>
Tue, 21 Mar 2006 06:35:16 +0000 (22:35 -0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 21 Mar 2006 06:35:16 +0000 (22:35 -0800)
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/atm/suni.c

index 06817dec0c254defea15d36b24f62cda25b624c0..b1d063cc4fbe0f6903359bf3328566e0e50aee93 100644 (file)
@@ -188,7 +188,7 @@ static int suni_ioctl(struct atm_dev *dev,unsigned int cmd,void __user *arg)
                case SONET_GETDIAG:
                        return get_diag(dev,arg);
                case SONET_SETFRAMING:
-                       if (arg != SONET_FRAME_SONET) return -EINVAL;
+                       if ((int)(unsigned long)arg != SONET_FRAME_SONET) return -EINVAL;
                        return 0;
                case SONET_GETFRAMING:
                        return put_user(SONET_FRAME_SONET,(int __user *)arg) ?