[KJ] [PATCH 1/1] drivers/net/s2io.c unnecessary casts

0 views
Skip to first unread message

Masami Ichikawa

unread,
Oct 19, 2007, 12:38:12 PM10/19/07
to kernel-...@lists.linux-foundation.org
Hello.
The patch removes an unnecessary cast.

Signed-off-by: Masami Ichikawa <masa...@gmail.com>
---
diff --git a/drivers/net/s2io.c b/drivers/net/s2io.c
index 22e4054..c4678c1 100644
--- a/drivers/net/s2io.c
+++ b/drivers/net/s2io.c
@@ -768,8 +768,7 @@ static int init_shared_mem(struct s2io_nic *nic)
while (k != rxd_count[nic->rxd_mode]) {
ba = &mac_control->rings[i].ba[j][k];

- ba->ba_0_org = (void *) kmalloc
- (BUF0_LEN + ALIGN_SIZE, GFP_KERNEL);
+ ba->ba_0_org = kmalloc(BUF0_LEN + ALIGN_SIZE, GFP_KERNEL);
if (!ba->ba_0_org)
return -ENOMEM;
mem_allocated +=
@@ -779,8 +778,7 @@ static int init_shared_mem(struct s2io_nic *nic)
tmp &= ~((unsigned long) ALIGN_SIZE);
ba->ba_0 = (void *) tmp;

- ba->ba_1_org = (void *) kmalloc
- (BUF1_LEN + ALIGN_SIZE, GFP_KERNEL);
+ ba->ba_1_org = kmalloc(BUF1_LEN + ALIGN_SIZE, GFP_KERNEL);
if (!ba->ba_1_org)
return -ENOMEM;
mem_allocated

Cheers,
--
/*
* Masami Ichikawa
* mailto: masa...@gmail.com
*/
_______________________________________________
REMINDER: this mailing list moved to vger.kernel.org and current one will be discontinued soon.
To resubscribe, send email to majo...@vger.kernel.org with
&quot;subscribe kernel-janitors&quot; in message body and follow instructions.

Kernel-janitors mailing list
Kernel-...@lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/kernel-janitors

Reply all
Reply to author
Forward
0 new messages