aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJamal Hadi Salim <hadi@cyberus.ca>2006-11-27 15:59:30 -0500
committerDavid S. Miller <davem@sunset.davemloft.net>2006-12-03 00:30:50 -0500
commitb798a9ede2b2434b9cbf0f3aee3e8598586fa89c (patch)
tree604e1009e43623b79df4abdccae7a1e117adc068
parent0c51f53c57c5584508dfae7110db5caccfd499c6 (diff)
[XFRM]: Convert a few __u8 to proper u8
Caught by the EyeBalls(tm) of Thomas Graf Signed-off-by: Jamal Hadi Salim <hadi@cyberus.ca> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/xfrm/xfrm_user.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/net/xfrm/xfrm_user.c b/net/xfrm/xfrm_user.c
index 006c88c163e0..6b461da0b51c 100644
--- a/net/xfrm/xfrm_user.c
+++ b/net/xfrm/xfrm_user.c
@@ -769,7 +769,7 @@ out_noput:
769 return err; 769 return err;
770} 770}
771 771
772static int verify_policy_dir(__u8 dir) 772static int verify_policy_dir(u8 dir)
773{ 773{
774 switch (dir) { 774 switch (dir) {
775 case XFRM_POLICY_IN: 775 case XFRM_POLICY_IN:
@@ -784,7 +784,7 @@ static int verify_policy_dir(__u8 dir)
784 return 0; 784 return 0;
785} 785}
786 786
787static int verify_policy_type(__u8 type) 787static int verify_policy_type(u8 type)
788{ 788{
789 switch (type) { 789 switch (type) {
790 case XFRM_POLICY_TYPE_MAIN: 790 case XFRM_POLICY_TYPE_MAIN:
@@ -897,7 +897,7 @@ static int copy_from_user_policy_type(u8 *tp, struct rtattr **xfrma)
897{ 897{
898 struct rtattr *rt = xfrma[XFRMA_POLICY_TYPE-1]; 898 struct rtattr *rt = xfrma[XFRMA_POLICY_TYPE-1];
899 struct xfrm_userpolicy_type *upt; 899 struct xfrm_userpolicy_type *upt;
900 __u8 type = XFRM_POLICY_TYPE_MAIN; 900 u8 type = XFRM_POLICY_TYPE_MAIN;
901 int err; 901 int err;
902 902
903 if (rt) { 903 if (rt) {
@@ -1079,7 +1079,7 @@ static inline int copy_to_user_sec_ctx(struct xfrm_policy *xp, struct sk_buff *s
1079} 1079}
1080 1080
1081#ifdef CONFIG_XFRM_SUB_POLICY 1081#ifdef CONFIG_XFRM_SUB_POLICY
1082static int copy_to_user_policy_type(__u8 type, struct sk_buff *skb) 1082static int copy_to_user_policy_type(u8 type, struct sk_buff *skb)
1083{ 1083{
1084 struct xfrm_userpolicy_type upt; 1084 struct xfrm_userpolicy_type upt;
1085 1085
@@ -1095,7 +1095,7 @@ rtattr_failure:
1095} 1095}
1096 1096
1097#else 1097#else
1098static inline int copy_to_user_policy_type(__u8 type, struct sk_buff *skb) 1098static inline int copy_to_user_policy_type(u8 type, struct sk_buff *skb)
1099{ 1099{
1100 return 0; 1100 return 0;
1101} 1101}
@@ -1185,7 +1185,7 @@ static int xfrm_get_policy(struct sk_buff *skb, struct nlmsghdr *nlh, void **xfr
1185{ 1185{
1186 struct xfrm_policy *xp; 1186 struct xfrm_policy *xp;
1187 struct xfrm_userpolicy_id *p; 1187 struct xfrm_userpolicy_id *p;
1188 __u8 type = XFRM_POLICY_TYPE_MAIN; 1188 u8 type = XFRM_POLICY_TYPE_MAIN;
1189 int err; 1189 int err;
1190 struct km_event c; 1190 struct km_event c;
1191 int delete; 1191 int delete;
@@ -1403,7 +1403,7 @@ out:
1403static int xfrm_flush_policy(struct sk_buff *skb, struct nlmsghdr *nlh, void **xfrma) 1403static int xfrm_flush_policy(struct sk_buff *skb, struct nlmsghdr *nlh, void **xfrma)
1404{ 1404{
1405 struct km_event c; 1405 struct km_event c;
1406 __u8 type = XFRM_POLICY_TYPE_MAIN; 1406 u8 type = XFRM_POLICY_TYPE_MAIN;
1407 int err; 1407 int err;
1408 1408
1409 err = copy_from_user_policy_type(&type, (struct rtattr **)xfrma); 1409 err = copy_from_user_policy_type(&type, (struct rtattr **)xfrma);
@@ -1424,7 +1424,7 @@ static int xfrm_add_pol_expire(struct sk_buff *skb, struct nlmsghdr *nlh, void *
1424 struct xfrm_policy *xp; 1424 struct xfrm_policy *xp;
1425 struct xfrm_user_polexpire *up = NLMSG_DATA(nlh); 1425 struct xfrm_user_polexpire *up = NLMSG_DATA(nlh);
1426 struct xfrm_userpolicy_info *p = &up->pol; 1426 struct xfrm_userpolicy_info *p = &up->pol;
1427 __u8 type = XFRM_POLICY_TYPE_MAIN; 1427 u8 type = XFRM_POLICY_TYPE_MAIN;
1428 int err = -ENOENT; 1428 int err = -ENOENT;
1429 1429
1430 err = copy_from_user_policy_type(&type, (struct rtattr **)xfrma); 1430 err = copy_from_user_policy_type(&type, (struct rtattr **)xfrma);