summaryrefslogtreecommitdiff
path: root/drivers/extcon
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/extcon')
-rw-r--r--drivers/extcon/extcon.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/drivers/extcon/extcon.c b/drivers/extcon/extcon.c
index b5d32236da68..b2c6a1660c51 100644
--- a/drivers/extcon/extcon.c
+++ b/drivers/extcon/extcon.c
@@ -1098,8 +1098,7 @@ static int extcon_alloc_cables(struct extcon_dev *edev)
if (!edev->max_supported)
return 0;
- edev->cables = kzalloc_objs(*edev->cables, edev->max_supported,
- GFP_KERNEL);
+ edev->cables = kzalloc_objs(*edev->cables, edev->max_supported);
if (!edev->cables)
return -ENOMEM;
@@ -1160,13 +1159,11 @@ static int extcon_alloc_muex(struct extcon_dev *edev)
for (index = 0; edev->mutually_exclusive[index]; index++)
;
- edev->attrs_muex = kzalloc_objs(*edev->attrs_muex, index + 1,
- GFP_KERNEL);
+ edev->attrs_muex = kzalloc_objs(*edev->attrs_muex, index + 1);
if (!edev->attrs_muex)
return -ENOMEM;
- edev->d_attrs_muex = kzalloc_objs(*edev->d_attrs_muex, index,
- GFP_KERNEL);
+ edev->d_attrs_muex = kzalloc_objs(*edev->d_attrs_muex, index);
if (!edev->d_attrs_muex) {
kfree(edev->attrs_muex);
return -ENOMEM;
@@ -1294,8 +1291,7 @@ int extcon_dev_register(struct extcon_dev *edev)
spin_lock_init(&edev->lock);
if (edev->max_supported) {
- edev->nh = kzalloc_objs(*edev->nh, edev->max_supported,
- GFP_KERNEL);
+ edev->nh = kzalloc_objs(*edev->nh, edev->max_supported);
if (!edev->nh) {
ret = -ENOMEM;
goto err_alloc_nh;