diff options
author | Heiko Carstens <heiko.carstens@de.ibm.com> | 2006-07-12 10:41:55 -0400 |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2006-07-12 10:41:55 -0400 |
commit | d2c993d845781d160a7ef759a3e65c6892c4a270 (patch) | |
tree | f63be38ab83363282c519048849663201f664818 /drivers/s390/char/raw3270.c | |
parent | 7e560814de1972e1bfc780616841d7a0032ca467 (diff) |
[S390] Fix sparse warnings.
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/char/raw3270.c')
-rw-r--r-- | drivers/s390/char/raw3270.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/drivers/s390/char/raw3270.c b/drivers/s390/char/raw3270.c index e95b56f810db..95e285b2e25c 100644 --- a/drivers/s390/char/raw3270.c +++ b/drivers/s390/char/raw3270.c | |||
@@ -555,7 +555,7 @@ raw3270_start_init(struct raw3270 *rp, struct raw3270_view *view, | |||
555 | #ifdef CONFIG_TN3270_CONSOLE | 555 | #ifdef CONFIG_TN3270_CONSOLE |
556 | if (raw3270_registered == 0) { | 556 | if (raw3270_registered == 0) { |
557 | spin_lock_irqsave(get_ccwdev_lock(view->dev->cdev), flags); | 557 | spin_lock_irqsave(get_ccwdev_lock(view->dev->cdev), flags); |
558 | rq->callback = 0; | 558 | rq->callback = NULL; |
559 | rc = __raw3270_start(rp, view, rq); | 559 | rc = __raw3270_start(rp, view, rq); |
560 | if (rc == 0) | 560 | if (rc == 0) |
561 | while (!raw3270_request_final(rq)) { | 561 | while (!raw3270_request_final(rq)) { |
@@ -719,8 +719,8 @@ raw3270_size_device(struct raw3270 *rp) | |||
719 | rc = __raw3270_size_device_vm(rp); | 719 | rc = __raw3270_size_device_vm(rp); |
720 | else | 720 | else |
721 | rc = __raw3270_size_device(rp); | 721 | rc = __raw3270_size_device(rp); |
722 | raw3270_init_view.dev = 0; | 722 | raw3270_init_view.dev = NULL; |
723 | rp->view = 0; | 723 | rp->view = NULL; |
724 | up(&raw3270_init_sem); | 724 | up(&raw3270_init_sem); |
725 | if (rc == 0) { /* Found something. */ | 725 | if (rc == 0) { /* Found something. */ |
726 | /* Try to find a model. */ | 726 | /* Try to find a model. */ |
@@ -761,8 +761,8 @@ raw3270_reset_device(struct raw3270 *rp) | |||
761 | rp->view = &raw3270_init_view; | 761 | rp->view = &raw3270_init_view; |
762 | raw3270_init_view.dev = rp; | 762 | raw3270_init_view.dev = rp; |
763 | rc = raw3270_start_init(rp, &raw3270_init_view, &rp->init_request); | 763 | rc = raw3270_start_init(rp, &raw3270_init_view, &rp->init_request); |
764 | raw3270_init_view.dev = 0; | 764 | raw3270_init_view.dev = NULL; |
765 | rp->view = 0; | 765 | rp->view = NULL; |
766 | up(&raw3270_init_sem); | 766 | up(&raw3270_init_sem); |
767 | return rc; | 767 | return rc; |
768 | } | 768 | } |
@@ -934,7 +934,7 @@ raw3270_activate_view(struct raw3270_view *view) | |||
934 | else if (!test_bit(RAW3270_FLAGS_READY, &rp->flags)) | 934 | else if (!test_bit(RAW3270_FLAGS_READY, &rp->flags)) |
935 | rc = -ENODEV; | 935 | rc = -ENODEV; |
936 | else { | 936 | else { |
937 | oldview = 0; | 937 | oldview = NULL; |
938 | if (rp->view) { | 938 | if (rp->view) { |
939 | oldview = rp->view; | 939 | oldview = rp->view; |
940 | oldview->fn->deactivate(oldview); | 940 | oldview->fn->deactivate(oldview); |
@@ -951,7 +951,7 @@ raw3270_activate_view(struct raw3270_view *view) | |||
951 | rp->view = nv; | 951 | rp->view = nv; |
952 | if (nv->fn->activate(nv) == 0) | 952 | if (nv->fn->activate(nv) == 0) |
953 | break; | 953 | break; |
954 | rp->view = 0; | 954 | rp->view = NULL; |
955 | } | 955 | } |
956 | } | 956 | } |
957 | } | 957 | } |
@@ -975,7 +975,7 @@ raw3270_deactivate_view(struct raw3270_view *view) | |||
975 | spin_lock_irqsave(get_ccwdev_lock(rp->cdev), flags); | 975 | spin_lock_irqsave(get_ccwdev_lock(rp->cdev), flags); |
976 | if (rp->view == view) { | 976 | if (rp->view == view) { |
977 | view->fn->deactivate(view); | 977 | view->fn->deactivate(view); |
978 | rp->view = 0; | 978 | rp->view = NULL; |
979 | /* Move deactivated view to end of list. */ | 979 | /* Move deactivated view to end of list. */ |
980 | list_del_init(&view->list); | 980 | list_del_init(&view->list); |
981 | list_add_tail(&view->list, &rp->view_list); | 981 | list_add_tail(&view->list, &rp->view_list); |
@@ -985,7 +985,7 @@ raw3270_deactivate_view(struct raw3270_view *view) | |||
985 | rp->view = view; | 985 | rp->view = view; |
986 | if (view->fn->activate(view) == 0) | 986 | if (view->fn->activate(view) == 0) |
987 | break; | 987 | break; |
988 | rp->view = 0; | 988 | rp->view = NULL; |
989 | } | 989 | } |
990 | } | 990 | } |
991 | } | 991 | } |
@@ -1076,7 +1076,7 @@ raw3270_del_view(struct raw3270_view *view) | |||
1076 | spin_lock_irqsave(get_ccwdev_lock(rp->cdev), flags); | 1076 | spin_lock_irqsave(get_ccwdev_lock(rp->cdev), flags); |
1077 | if (rp->view == view) { | 1077 | if (rp->view == view) { |
1078 | view->fn->deactivate(view); | 1078 | view->fn->deactivate(view); |
1079 | rp->view = 0; | 1079 | rp->view = NULL; |
1080 | } | 1080 | } |
1081 | list_del_init(&view->list); | 1081 | list_del_init(&view->list); |
1082 | if (!rp->view && test_bit(RAW3270_FLAGS_READY, &rp->flags)) { | 1082 | if (!rp->view && test_bit(RAW3270_FLAGS_READY, &rp->flags)) { |
@@ -1117,9 +1117,9 @@ raw3270_delete_device(struct raw3270 *rp) | |||
1117 | 1117 | ||
1118 | /* Disconnect from ccw_device. */ | 1118 | /* Disconnect from ccw_device. */ |
1119 | cdev = rp->cdev; | 1119 | cdev = rp->cdev; |
1120 | rp->cdev = 0; | 1120 | rp->cdev = NULL; |
1121 | cdev->dev.driver_data = 0; | 1121 | cdev->dev.driver_data = NULL; |
1122 | cdev->handler = 0; | 1122 | cdev->handler = NULL; |
1123 | 1123 | ||
1124 | /* Put ccw_device structure. */ | 1124 | /* Put ccw_device structure. */ |
1125 | put_device(&cdev->dev); | 1125 | put_device(&cdev->dev); |
@@ -1144,7 +1144,7 @@ raw3270_model_show(struct device *dev, struct device_attribute *attr, char *buf) | |||
1144 | return snprintf(buf, PAGE_SIZE, "%i\n", | 1144 | return snprintf(buf, PAGE_SIZE, "%i\n", |
1145 | ((struct raw3270 *) dev->driver_data)->model); | 1145 | ((struct raw3270 *) dev->driver_data)->model); |
1146 | } | 1146 | } |
1147 | static DEVICE_ATTR(model, 0444, raw3270_model_show, 0); | 1147 | static DEVICE_ATTR(model, 0444, raw3270_model_show, NULL); |
1148 | 1148 | ||
1149 | static ssize_t | 1149 | static ssize_t |
1150 | raw3270_rows_show(struct device *dev, struct device_attribute *attr, char *buf) | 1150 | raw3270_rows_show(struct device *dev, struct device_attribute *attr, char *buf) |
@@ -1152,7 +1152,7 @@ raw3270_rows_show(struct device *dev, struct device_attribute *attr, char *buf) | |||
1152 | return snprintf(buf, PAGE_SIZE, "%i\n", | 1152 | return snprintf(buf, PAGE_SIZE, "%i\n", |
1153 | ((struct raw3270 *) dev->driver_data)->rows); | 1153 | ((struct raw3270 *) dev->driver_data)->rows); |
1154 | } | 1154 | } |
1155 | static DEVICE_ATTR(rows, 0444, raw3270_rows_show, 0); | 1155 | static DEVICE_ATTR(rows, 0444, raw3270_rows_show, NULL); |
1156 | 1156 | ||
1157 | static ssize_t | 1157 | static ssize_t |
1158 | raw3270_columns_show(struct device *dev, struct device_attribute *attr, char *buf) | 1158 | raw3270_columns_show(struct device *dev, struct device_attribute *attr, char *buf) |
@@ -1160,7 +1160,7 @@ raw3270_columns_show(struct device *dev, struct device_attribute *attr, char *bu | |||
1160 | return snprintf(buf, PAGE_SIZE, "%i\n", | 1160 | return snprintf(buf, PAGE_SIZE, "%i\n", |
1161 | ((struct raw3270 *) dev->driver_data)->cols); | 1161 | ((struct raw3270 *) dev->driver_data)->cols); |
1162 | } | 1162 | } |
1163 | static DEVICE_ATTR(columns, 0444, raw3270_columns_show, 0); | 1163 | static DEVICE_ATTR(columns, 0444, raw3270_columns_show, NULL); |
1164 | 1164 | ||
1165 | static struct attribute * raw3270_attrs[] = { | 1165 | static struct attribute * raw3270_attrs[] = { |
1166 | &dev_attr_model.attr, | 1166 | &dev_attr_model.attr, |
@@ -1296,7 +1296,7 @@ raw3270_remove (struct ccw_device *cdev) | |||
1296 | spin_lock_irqsave(get_ccwdev_lock(cdev), flags); | 1296 | spin_lock_irqsave(get_ccwdev_lock(cdev), flags); |
1297 | if (rp->view) { | 1297 | if (rp->view) { |
1298 | rp->view->fn->deactivate(rp->view); | 1298 | rp->view->fn->deactivate(rp->view); |
1299 | rp->view = 0; | 1299 | rp->view = NULL; |
1300 | } | 1300 | } |
1301 | while (!list_empty(&rp->view_list)) { | 1301 | while (!list_empty(&rp->view_list)) { |
1302 | v = list_entry(rp->view_list.next, struct raw3270_view, list); | 1302 | v = list_entry(rp->view_list.next, struct raw3270_view, list); |