diff options
author | James Bottomley <jejb@titanic.(none)> | 2005-11-10 09:29:07 -0500 |
---|---|---|
committer | James Bottomley <jejb@titanic.(none)> | 2005-11-10 09:29:07 -0500 |
commit | 8a87a0b6313109d2fea87b1271d497c954ce2ca8 (patch) | |
tree | 1b7ae51ff681e27118590e9cab4bf0ce38f5d80e /drivers/net/wireless/airo.c | |
parent | e6a04466ba965875a6132700fabb2f2c0249c41a (diff) | |
parent | 3b44f137b9a846c5452d9e6e1271b79b1dbcc942 (diff) |
Merge by hand (whitespace conflicts in libata.h)
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/net/wireless/airo.c')
-rw-r--r-- | drivers/net/wireless/airo.c | 36 |
1 files changed, 12 insertions, 24 deletions
diff --git a/drivers/net/wireless/airo.c b/drivers/net/wireless/airo.c index 6afc6e5dee9b..340ab4ee4b67 100644 --- a/drivers/net/wireless/airo.c +++ b/drivers/net/wireless/airo.c | |||
@@ -4535,9 +4535,8 @@ static int proc_status_open( struct inode *inode, struct file *file ) { | |||
4535 | StatusRid status_rid; | 4535 | StatusRid status_rid; |
4536 | int i; | 4536 | int i; |
4537 | 4537 | ||
4538 | if ((file->private_data = kmalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) | 4538 | if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) |
4539 | return -ENOMEM; | 4539 | return -ENOMEM; |
4540 | memset(file->private_data, 0, sizeof(struct proc_data)); | ||
4541 | data = (struct proc_data *)file->private_data; | 4540 | data = (struct proc_data *)file->private_data; |
4542 | if ((data->rbuffer = kmalloc( 2048, GFP_KERNEL )) == NULL) { | 4541 | if ((data->rbuffer = kmalloc( 2048, GFP_KERNEL )) == NULL) { |
4543 | kfree (file->private_data); | 4542 | kfree (file->private_data); |
@@ -4615,9 +4614,8 @@ static int proc_stats_rid_open( struct inode *inode, | |||
4615 | int i, j; | 4614 | int i, j; |
4616 | u32 *vals = stats.vals; | 4615 | u32 *vals = stats.vals; |
4617 | 4616 | ||
4618 | if ((file->private_data = kmalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) | 4617 | if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) |
4619 | return -ENOMEM; | 4618 | return -ENOMEM; |
4620 | memset(file->private_data, 0, sizeof(struct proc_data)); | ||
4621 | data = (struct proc_data *)file->private_data; | 4619 | data = (struct proc_data *)file->private_data; |
4622 | if ((data->rbuffer = kmalloc( 4096, GFP_KERNEL )) == NULL) { | 4620 | if ((data->rbuffer = kmalloc( 4096, GFP_KERNEL )) == NULL) { |
4623 | kfree (file->private_data); | 4621 | kfree (file->private_data); |
@@ -4881,20 +4879,18 @@ static int proc_config_open( struct inode *inode, struct file *file ) { | |||
4881 | struct airo_info *ai = dev->priv; | 4879 | struct airo_info *ai = dev->priv; |
4882 | int i; | 4880 | int i; |
4883 | 4881 | ||
4884 | if ((file->private_data = kmalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) | 4882 | if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) |
4885 | return -ENOMEM; | 4883 | return -ENOMEM; |
4886 | memset(file->private_data, 0, sizeof(struct proc_data)); | ||
4887 | data = (struct proc_data *)file->private_data; | 4884 | data = (struct proc_data *)file->private_data; |
4888 | if ((data->rbuffer = kmalloc( 2048, GFP_KERNEL )) == NULL) { | 4885 | if ((data->rbuffer = kmalloc( 2048, GFP_KERNEL )) == NULL) { |
4889 | kfree (file->private_data); | 4886 | kfree (file->private_data); |
4890 | return -ENOMEM; | 4887 | return -ENOMEM; |
4891 | } | 4888 | } |
4892 | if ((data->wbuffer = kmalloc( 2048, GFP_KERNEL )) == NULL) { | 4889 | if ((data->wbuffer = kzalloc( 2048, GFP_KERNEL )) == NULL) { |
4893 | kfree (data->rbuffer); | 4890 | kfree (data->rbuffer); |
4894 | kfree (file->private_data); | 4891 | kfree (file->private_data); |
4895 | return -ENOMEM; | 4892 | return -ENOMEM; |
4896 | } | 4893 | } |
4897 | memset( data->wbuffer, 0, 2048 ); | ||
4898 | data->maxwritelen = 2048; | 4894 | data->maxwritelen = 2048; |
4899 | data->on_close = proc_config_on_close; | 4895 | data->on_close = proc_config_on_close; |
4900 | 4896 | ||
@@ -5155,24 +5151,21 @@ static int proc_wepkey_open( struct inode *inode, struct file *file ) { | |||
5155 | int j=0; | 5151 | int j=0; |
5156 | int rc; | 5152 | int rc; |
5157 | 5153 | ||
5158 | if ((file->private_data = kmalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) | 5154 | if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) |
5159 | return -ENOMEM; | 5155 | return -ENOMEM; |
5160 | memset(file->private_data, 0, sizeof(struct proc_data)); | ||
5161 | memset(&wkr, 0, sizeof(wkr)); | 5156 | memset(&wkr, 0, sizeof(wkr)); |
5162 | data = (struct proc_data *)file->private_data; | 5157 | data = (struct proc_data *)file->private_data; |
5163 | if ((data->rbuffer = kmalloc( 180, GFP_KERNEL )) == NULL) { | 5158 | if ((data->rbuffer = kzalloc( 180, GFP_KERNEL )) == NULL) { |
5164 | kfree (file->private_data); | 5159 | kfree (file->private_data); |
5165 | return -ENOMEM; | 5160 | return -ENOMEM; |
5166 | } | 5161 | } |
5167 | memset(data->rbuffer, 0, 180); | ||
5168 | data->writelen = 0; | 5162 | data->writelen = 0; |
5169 | data->maxwritelen = 80; | 5163 | data->maxwritelen = 80; |
5170 | if ((data->wbuffer = kmalloc( 80, GFP_KERNEL )) == NULL) { | 5164 | if ((data->wbuffer = kzalloc( 80, GFP_KERNEL )) == NULL) { |
5171 | kfree (data->rbuffer); | 5165 | kfree (data->rbuffer); |
5172 | kfree (file->private_data); | 5166 | kfree (file->private_data); |
5173 | return -ENOMEM; | 5167 | return -ENOMEM; |
5174 | } | 5168 | } |
5175 | memset( data->wbuffer, 0, 80 ); | ||
5176 | data->on_close = proc_wepkey_on_close; | 5169 | data->on_close = proc_wepkey_on_close; |
5177 | 5170 | ||
5178 | ptr = data->rbuffer; | 5171 | ptr = data->rbuffer; |
@@ -5203,9 +5196,8 @@ static int proc_SSID_open( struct inode *inode, struct file *file ) { | |||
5203 | char *ptr; | 5196 | char *ptr; |
5204 | SsidRid SSID_rid; | 5197 | SsidRid SSID_rid; |
5205 | 5198 | ||
5206 | if ((file->private_data = kmalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) | 5199 | if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) |
5207 | return -ENOMEM; | 5200 | return -ENOMEM; |
5208 | memset(file->private_data, 0, sizeof(struct proc_data)); | ||
5209 | data = (struct proc_data *)file->private_data; | 5201 | data = (struct proc_data *)file->private_data; |
5210 | if ((data->rbuffer = kmalloc( 104, GFP_KERNEL )) == NULL) { | 5202 | if ((data->rbuffer = kmalloc( 104, GFP_KERNEL )) == NULL) { |
5211 | kfree (file->private_data); | 5203 | kfree (file->private_data); |
@@ -5213,12 +5205,11 @@ static int proc_SSID_open( struct inode *inode, struct file *file ) { | |||
5213 | } | 5205 | } |
5214 | data->writelen = 0; | 5206 | data->writelen = 0; |
5215 | data->maxwritelen = 33*3; | 5207 | data->maxwritelen = 33*3; |
5216 | if ((data->wbuffer = kmalloc( 33*3, GFP_KERNEL )) == NULL) { | 5208 | if ((data->wbuffer = kzalloc( 33*3, GFP_KERNEL )) == NULL) { |
5217 | kfree (data->rbuffer); | 5209 | kfree (data->rbuffer); |
5218 | kfree (file->private_data); | 5210 | kfree (file->private_data); |
5219 | return -ENOMEM; | 5211 | return -ENOMEM; |
5220 | } | 5212 | } |
5221 | memset( data->wbuffer, 0, 33*3 ); | ||
5222 | data->on_close = proc_SSID_on_close; | 5213 | data->on_close = proc_SSID_on_close; |
5223 | 5214 | ||
5224 | readSsidRid(ai, &SSID_rid); | 5215 | readSsidRid(ai, &SSID_rid); |
@@ -5247,9 +5238,8 @@ static int proc_APList_open( struct inode *inode, struct file *file ) { | |||
5247 | char *ptr; | 5238 | char *ptr; |
5248 | APListRid APList_rid; | 5239 | APListRid APList_rid; |
5249 | 5240 | ||
5250 | if ((file->private_data = kmalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) | 5241 | if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) |
5251 | return -ENOMEM; | 5242 | return -ENOMEM; |
5252 | memset(file->private_data, 0, sizeof(struct proc_data)); | ||
5253 | data = (struct proc_data *)file->private_data; | 5243 | data = (struct proc_data *)file->private_data; |
5254 | if ((data->rbuffer = kmalloc( 104, GFP_KERNEL )) == NULL) { | 5244 | if ((data->rbuffer = kmalloc( 104, GFP_KERNEL )) == NULL) { |
5255 | kfree (file->private_data); | 5245 | kfree (file->private_data); |
@@ -5257,12 +5247,11 @@ static int proc_APList_open( struct inode *inode, struct file *file ) { | |||
5257 | } | 5247 | } |
5258 | data->writelen = 0; | 5248 | data->writelen = 0; |
5259 | data->maxwritelen = 4*6*3; | 5249 | data->maxwritelen = 4*6*3; |
5260 | if ((data->wbuffer = kmalloc( data->maxwritelen, GFP_KERNEL )) == NULL) { | 5250 | if ((data->wbuffer = kzalloc( data->maxwritelen, GFP_KERNEL )) == NULL) { |
5261 | kfree (data->rbuffer); | 5251 | kfree (data->rbuffer); |
5262 | kfree (file->private_data); | 5252 | kfree (file->private_data); |
5263 | return -ENOMEM; | 5253 | return -ENOMEM; |
5264 | } | 5254 | } |
5265 | memset( data->wbuffer, 0, data->maxwritelen ); | ||
5266 | data->on_close = proc_APList_on_close; | 5255 | data->on_close = proc_APList_on_close; |
5267 | 5256 | ||
5268 | readAPListRid(ai, &APList_rid); | 5257 | readAPListRid(ai, &APList_rid); |
@@ -5297,9 +5286,8 @@ static int proc_BSSList_open( struct inode *inode, struct file *file ) { | |||
5297 | /* If doLoseSync is not 1, we won't do a Lose Sync */ | 5286 | /* If doLoseSync is not 1, we won't do a Lose Sync */ |
5298 | int doLoseSync = -1; | 5287 | int doLoseSync = -1; |
5299 | 5288 | ||
5300 | if ((file->private_data = kmalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) | 5289 | if ((file->private_data = kzalloc(sizeof(struct proc_data ), GFP_KERNEL)) == NULL) |
5301 | return -ENOMEM; | 5290 | return -ENOMEM; |
5302 | memset(file->private_data, 0, sizeof(struct proc_data)); | ||
5303 | data = (struct proc_data *)file->private_data; | 5291 | data = (struct proc_data *)file->private_data; |
5304 | if ((data->rbuffer = kmalloc( 1024, GFP_KERNEL )) == NULL) { | 5292 | if ((data->rbuffer = kmalloc( 1024, GFP_KERNEL )) == NULL) { |
5305 | kfree (file->private_data); | 5293 | kfree (file->private_data); |