On Tue, Mar 25, 2014 at 09:30:18PM +0100, [email protected] wrote:
> From: Silvio F <[email protected]>
Don't use this header for your own patches.
>
> This patch fixes the following type of sparse warnings:
>
> drivers/staging/vt6655/wpactl.c:596:47: warning: cast from restricted gfp_t
> drivers/staging/vt6655/wpactl.c:638:68: warning: cast from restricted gfp_t
> drivers/staging/vt6655/wpactl.c:860:42: warning: cast from restricted gfp_t
>
> Signed-off-by: Silvio F <[email protected]>
We can't verify this is you if you don't send from the same email you
sign off by. We can't really verify perfectly anyway, of course, but
at least we try do the minimum.
regards,
dan carpenter
This patch fixes the following type of sparse warnings:
drivers/staging/vt6655/ioctl.c:308:104: warning: cast from restricted gfp_t
drivers/staging/vt6655/ioctl.c:579:109: warning: cast from restricted gfp_t
Signed-off-by: Silvio Fricke <[email protected]>
---
drivers/staging/vt6655/ioctl.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/vt6655/ioctl.c b/drivers/staging/vt6655/ioctl.c
index b5cd2e4..1de5d2c9 100644
--- a/drivers/staging/vt6655/ioctl.c
+++ b/drivers/staging/vt6655/ioctl.c
@@ -305,7 +305,8 @@ int private_ioctl(PSDevice pDevice, struct ifreq *rq)
result = -EINVAL;
break;
}
- pList = (PSBSSIDList)kmalloc(sizeof(SBSSIDList) + (sList.uItem * sizeof(SBSSIDItem)), (int)GFP_ATOMIC);
+ pList = (PSBSSIDList)kmalloc(sizeof(SBSSIDList) + (sList.uItem * sizeof(SBSSIDItem)),
+ GFP_ATOMIC);
if (pList == NULL) {
result = -ENOMEM;
break;
@@ -576,7 +577,8 @@ int private_ioctl(PSDevice pDevice, struct ifreq *rq)
result = -EINVAL;
break;
}
- pNodeList = (PSNodeList)kmalloc(sizeof(SNodeList) + (sNodeList.uItem * sizeof(SNodeItem)), (int)GFP_ATOMIC);
+ pNodeList = (PSNodeList)kmalloc(sizeof(SNodeList) + (sNodeList.uItem * sizeof(SNodeItem)),
+ GFP_ATOMIC);
if (pNodeList == NULL) {
result = -ENOMEM;
break;
--
1.9.0
This patch fixes the following type of sparse warnings:
drivers/staging/vt6655/wpactl.c:596:47: warning: cast from restricted gfp_t
drivers/staging/vt6655/wpactl.c:638:68: warning: cast from restricted gfp_t
drivers/staging/vt6655/wpactl.c:860:42: warning: cast from restricted gfp_t
Signed-off-by: Silvio Fricke <[email protected]>
---
drivers/staging/vt6655/wpactl.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/vt6655/wpactl.c b/drivers/staging/vt6655/wpactl.c
index d17224f..4745429 100644
--- a/drivers/staging/vt6655/wpactl.c
+++ b/drivers/staging/vt6655/wpactl.c
@@ -593,7 +593,7 @@ static int wpa_get_scan(PSDevice pDevice,
unsigned char *ptempBSS;
- ptempBSS = kmalloc(sizeof(KnownBSS), (int)GFP_ATOMIC);
+ ptempBSS = kmalloc(sizeof(KnownBSS), GFP_ATOMIC);
if (ptempBSS == NULL) {
printk(KERN_ERR "bubble sort kmalloc memory fail@@@\n");
@@ -635,7 +635,7 @@ static int wpa_get_scan(PSDevice pDevice,
count++;
}
- pBuf = kcalloc(count, sizeof(struct viawget_scan_result), (int)GFP_ATOMIC);
+ pBuf = kcalloc(count, sizeof(struct viawget_scan_result), GFP_ATOMIC);
if (pBuf == NULL) {
ret = -ENOMEM;
@@ -857,7 +857,7 @@ int wpa_ioctl(PSDevice pDevice, struct iw_point *p)
p->length > VIAWGET_WPA_MAX_BUF_SIZE || !p->pointer)
return -EINVAL;
- param = kmalloc((int)p->length, (int)GFP_KERNEL);
+ param = kmalloc((int)p->length, GFP_KERNEL);
if (param == NULL)
return -ENOMEM;
--
1.9.0
Hi Dan,
thanks for your review.
Attached second version of this series.
Cheers,
Silvio
Silvio Fricke (3):
staging: vt6655: removed incorrect casting in wpactl.c
staging: vt6655: removed incorrect casting in ioctl.c
staging: vt6655: removed incorrect casting in iwctl.c
drivers/staging/vt6655/ioctl.c | 6 ++++--
drivers/staging/vt6655/iwctl.c | 2 +-
drivers/staging/vt6655/wpactl.c | 6 +++---
3 files changed, 8 insertions(+), 6 deletions(-)
--
1.9.0
This patch fixes the following type of sparse warning:
drivers/staging/vt6655/iwctl.c:1846:35: warning: cast from restricted gfp_t
Signed-off-by: Silvio Fricke <[email protected]>
---
drivers/staging/vt6655/iwctl.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/vt6655/iwctl.c b/drivers/staging/vt6655/iwctl.c
index ac3fc16..5e25535 100644
--- a/drivers/staging/vt6655/iwctl.c
+++ b/drivers/staging/vt6655/iwctl.c
@@ -1843,7 +1843,7 @@ int iwctl_siwencodeext(struct net_device *dev,
PRINT_K("SIOCSIWENCODEEXT...... \n");
blen = sizeof(*param);
- buf = kmalloc((int)blen, (int)GFP_KERNEL);
+ buf = kmalloc((int)blen, GFP_KERNEL);
if (buf == NULL)
return -ENOMEM;
memset(buf, 0, blen);
--
1.9.0
On Sat, Apr 05, 2014 at 12:32:07AM +0200, Silvio Fricke wrote:
> Hi Dan,
>
> thanks for your review.
> Attached second version of this series.
I don't understand what the [WIP] marking is. Please just resend these
as "real" patches if you feel they are ready to be merged. If we have
issues with them, we will be sure to let you know :)
thanks,
greg k-h
Hi,
> > thanks for your review.
> > Attached second version of this series.
>
> I don't understand what the [WIP] marking is. Please just resend these
> as "real" patches if you feel they are ready to be merged. If we have
> issues with them, we will be sure to let you know :)
I removed it.
Bye,
Silvio
v3: * no 'WIP'! Don't do that!
v2: * signed-off and message are not the same address
Silvio Fricke (3):
staging: vt6655: removed incorrect casting in wpactl.c
staging: vt6655: removed incorrect casting in ioctl.c
staging: vt6655: removed incorrect casting in iwctl.c
drivers/staging/vt6655/ioctl.c | 6 ++++--
drivers/staging/vt6655/iwctl.c | 2 +-
drivers/staging/vt6655/wpactl.c | 6 +++---
3 files changed, 8 insertions(+), 6 deletions(-)
--
1.9.2
This patch fixes the following type of sparse warning:
drivers/staging/vt6655/iwctl.c:1846:35: warning: cast from restricted gfp_t
Signed-off-by: Silvio Fricke <[email protected]>
---
drivers/staging/vt6655/iwctl.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/vt6655/iwctl.c b/drivers/staging/vt6655/iwctl.c
index ac3fc16..5e25535 100644
--- a/drivers/staging/vt6655/iwctl.c
+++ b/drivers/staging/vt6655/iwctl.c
@@ -1843,7 +1843,7 @@ int iwctl_siwencodeext(struct net_device *dev,
PRINT_K("SIOCSIWENCODEEXT...... \n");
blen = sizeof(*param);
- buf = kmalloc((int)blen, (int)GFP_KERNEL);
+ buf = kmalloc((int)blen, GFP_KERNEL);
if (buf == NULL)
return -ENOMEM;
memset(buf, 0, blen);
--
1.9.2
This patch fixes the following type of sparse warnings:
drivers/staging/vt6655/wpactl.c:596:47: warning: cast from restricted gfp_t
drivers/staging/vt6655/wpactl.c:638:68: warning: cast from restricted gfp_t
drivers/staging/vt6655/wpactl.c:860:42: warning: cast from restricted gfp_t
Signed-off-by: Silvio Fricke <[email protected]>
---
drivers/staging/vt6655/wpactl.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/vt6655/wpactl.c b/drivers/staging/vt6655/wpactl.c
index d17224f..4745429 100644
--- a/drivers/staging/vt6655/wpactl.c
+++ b/drivers/staging/vt6655/wpactl.c
@@ -593,7 +593,7 @@ static int wpa_get_scan(PSDevice pDevice,
unsigned char *ptempBSS;
- ptempBSS = kmalloc(sizeof(KnownBSS), (int)GFP_ATOMIC);
+ ptempBSS = kmalloc(sizeof(KnownBSS), GFP_ATOMIC);
if (ptempBSS == NULL) {
printk(KERN_ERR "bubble sort kmalloc memory fail@@@\n");
@@ -635,7 +635,7 @@ static int wpa_get_scan(PSDevice pDevice,
count++;
}
- pBuf = kcalloc(count, sizeof(struct viawget_scan_result), (int)GFP_ATOMIC);
+ pBuf = kcalloc(count, sizeof(struct viawget_scan_result), GFP_ATOMIC);
if (pBuf == NULL) {
ret = -ENOMEM;
@@ -857,7 +857,7 @@ int wpa_ioctl(PSDevice pDevice, struct iw_point *p)
p->length > VIAWGET_WPA_MAX_BUF_SIZE || !p->pointer)
return -EINVAL;
- param = kmalloc((int)p->length, (int)GFP_KERNEL);
+ param = kmalloc((int)p->length, GFP_KERNEL);
if (param == NULL)
return -ENOMEM;
--
1.9.2
This patch fixes the following type of sparse warnings:
drivers/staging/vt6655/ioctl.c:308:104: warning: cast from restricted gfp_t
drivers/staging/vt6655/ioctl.c:579:109: warning: cast from restricted gfp_t
Signed-off-by: Silvio Fricke <[email protected]>
---
drivers/staging/vt6655/ioctl.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/vt6655/ioctl.c b/drivers/staging/vt6655/ioctl.c
index b5cd2e4..1de5d2c9 100644
--- a/drivers/staging/vt6655/ioctl.c
+++ b/drivers/staging/vt6655/ioctl.c
@@ -305,7 +305,8 @@ int private_ioctl(PSDevice pDevice, struct ifreq *rq)
result = -EINVAL;
break;
}
- pList = (PSBSSIDList)kmalloc(sizeof(SBSSIDList) + (sList.uItem * sizeof(SBSSIDItem)), (int)GFP_ATOMIC);
+ pList = (PSBSSIDList)kmalloc(sizeof(SBSSIDList) + (sList.uItem * sizeof(SBSSIDItem)),
+ GFP_ATOMIC);
if (pList == NULL) {
result = -ENOMEM;
break;
@@ -576,7 +577,8 @@ int private_ioctl(PSDevice pDevice, struct ifreq *rq)
result = -EINVAL;
break;
}
- pNodeList = (PSNodeList)kmalloc(sizeof(SNodeList) + (sNodeList.uItem * sizeof(SNodeItem)), (int)GFP_ATOMIC);
+ pNodeList = (PSNodeList)kmalloc(sizeof(SNodeList) + (sNodeList.uItem * sizeof(SNodeItem)),
+ GFP_ATOMIC);
if (pNodeList == NULL) {
result = -ENOMEM;
break;
--
1.9.2