summaryrefslogtreecommitdiff
path: root/drivers/mtd/devices
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mtd/devices')
-rw-r--r--drivers/mtd/devices/block2mtd.c2
-rw-r--r--drivers/mtd/devices/docg3.c4
-rw-r--r--drivers/mtd/devices/ms02-nv.c12
-rw-r--r--drivers/mtd/devices/mtd_dataflash.c2
-rw-r--r--drivers/mtd/devices/mtd_intel_dg.c2
-rw-r--r--drivers/mtd/devices/mtdram.c2
-rw-r--r--drivers/mtd/devices/phram.c2
-rw-r--r--drivers/mtd/devices/pmc551.c4
-rw-r--r--drivers/mtd/devices/slram.c6
9 files changed, 18 insertions, 18 deletions
diff --git a/drivers/mtd/devices/block2mtd.c b/drivers/mtd/devices/block2mtd.c
index 41b1c1348efe..03e80b2c4f5a 100644
--- a/drivers/mtd/devices/block2mtd.c
+++ b/drivers/mtd/devices/block2mtd.c
@@ -271,7 +271,7 @@ static struct block2mtd_dev *add_device(char *devname, int erase_size,
if (!devname)
return NULL;
- dev = kzalloc_obj(struct block2mtd_dev, GFP_KERNEL);
+ dev = kzalloc_obj(struct block2mtd_dev);
if (!dev)
return NULL;
diff --git a/drivers/mtd/devices/docg3.c b/drivers/mtd/devices/docg3.c
index 8db760b2c900..33050a2a80f7 100644
--- a/drivers/mtd/devices/docg3.c
+++ b/drivers/mtd/devices/docg3.c
@@ -1810,10 +1810,10 @@ doc_probe_device(struct docg3_cascade *cascade, int floor, struct device *dev)
struct mtd_info *mtd;
ret = -ENOMEM;
- docg3 = kzalloc_obj(struct docg3, GFP_KERNEL);
+ docg3 = kzalloc_obj(struct docg3);
if (!docg3)
goto nomem1;
- mtd = kzalloc_obj(struct mtd_info, GFP_KERNEL);
+ mtd = kzalloc_obj(struct mtd_info);
if (!mtd)
goto nomem2;
mtd->priv = docg3;
diff --git a/drivers/mtd/devices/ms02-nv.c b/drivers/mtd/devices/ms02-nv.c
index 0a5d6ca1fe2f..453b3e05feb7 100644
--- a/drivers/mtd/devices/ms02-nv.c
+++ b/drivers/mtd/devices/ms02-nv.c
@@ -117,7 +117,7 @@ static int __init ms02nv_init_one(ulong addr)
int ret = -ENODEV;
/* The module decodes 8MiB of address space. */
- mod_res = kzalloc_obj(*mod_res, GFP_KERNEL);
+ mod_res = kzalloc_obj(*mod_res);
if (!mod_res)
return -ENOMEM;
@@ -138,10 +138,10 @@ static int __init ms02nv_init_one(ulong addr)
}
ret = -ENOMEM;
- mtd = kzalloc_obj(*mtd, GFP_KERNEL);
+ mtd = kzalloc_obj(*mtd);
if (!mtd)
goto err_out_mod_res_rel;
- mp = kzalloc_obj(*mp, GFP_KERNEL);
+ mp = kzalloc_obj(*mp);
if (!mp)
goto err_out_mtd;
@@ -149,7 +149,7 @@ static int __init ms02nv_init_one(ulong addr)
mp->resource.module = mod_res;
/* Firmware's diagnostic NVRAM area. */
- diag_res = kzalloc_obj(*diag_res, GFP_KERNEL);
+ diag_res = kzalloc_obj(*diag_res);
if (!diag_res)
goto err_out_mp;
@@ -162,7 +162,7 @@ static int __init ms02nv_init_one(ulong addr)
mp->resource.diag_ram = diag_res;
/* User-available general-purpose NVRAM area. */
- user_res = kzalloc_obj(*user_res, GFP_KERNEL);
+ user_res = kzalloc_obj(*user_res);
if (!user_res)
goto err_out_diag_res;
@@ -175,7 +175,7 @@ static int __init ms02nv_init_one(ulong addr)
mp->resource.user_ram = user_res;
/* Control and status register. */
- csr_res = kzalloc_obj(*csr_res, GFP_KERNEL);
+ csr_res = kzalloc_obj(*csr_res);
if (!csr_res)
goto err_out_user_res;
diff --git a/drivers/mtd/devices/mtd_dataflash.c b/drivers/mtd/devices/mtd_dataflash.c
index 3eebca290f50..e766258d76f7 100644
--- a/drivers/mtd/devices/mtd_dataflash.c
+++ b/drivers/mtd/devices/mtd_dataflash.c
@@ -627,7 +627,7 @@ static int add_dataflash_otp(struct spi_device *spi, char *name, int nr_pages,
char *otp_tag = "";
int err = 0;
- priv = kzalloc_obj(*priv, GFP_KERNEL);
+ priv = kzalloc_obj(*priv);
if (!priv)
return -ENOMEM;
diff --git a/drivers/mtd/devices/mtd_intel_dg.c b/drivers/mtd/devices/mtd_intel_dg.c
index ed5a07459012..c4c736ead0e5 100644
--- a/drivers/mtd/devices/mtd_intel_dg.c
+++ b/drivers/mtd/devices/mtd_intel_dg.c
@@ -720,7 +720,7 @@ static int intel_dg_nvm_init_mtd(struct intel_dg_nvm *nvm, struct device *device
nvm->mtd.erasesize = SZ_4K; /* 4K bytes granularity */
nvm->mtd.size = nvm->size;
- parts = kzalloc_objs(*parts, nvm->nregions, GFP_KERNEL);
+ parts = kzalloc_objs(*parts, nvm->nregions);
if (!parts)
return -ENOMEM;
diff --git a/drivers/mtd/devices/mtdram.c b/drivers/mtd/devices/mtdram.c
index 5418cfcfb1d9..3fff3cdd9834 100644
--- a/drivers/mtd/devices/mtdram.c
+++ b/drivers/mtd/devices/mtdram.c
@@ -158,7 +158,7 @@ static int __init init_mtdram(void)
return -EINVAL;
/* Allocate some memory */
- mtd_info = kmalloc_obj(struct mtd_info, GFP_KERNEL);
+ mtd_info = kmalloc_obj(struct mtd_info);
if (!mtd_info)
return -ENOMEM;
diff --git a/drivers/mtd/devices/phram.c b/drivers/mtd/devices/phram.c
index d35f43dec8e3..b42cadcd76b1 100644
--- a/drivers/mtd/devices/phram.c
+++ b/drivers/mtd/devices/phram.c
@@ -130,7 +130,7 @@ static int register_device(struct platform_device *pdev, const char *name,
struct phram_mtd_list *new;
int ret = -ENOMEM;
- new = kzalloc_obj(*new, GFP_KERNEL);
+ new = kzalloc_obj(*new);
if (!new)
goto out0;
diff --git a/drivers/mtd/devices/pmc551.c b/drivers/mtd/devices/pmc551.c
index 1d793bf7ad71..dc0ebfeb846e 100644
--- a/drivers/mtd/devices/pmc551.c
+++ b/drivers/mtd/devices/pmc551.c
@@ -715,11 +715,11 @@ static int __init init_pmc551(void)
msize = length;
}
- mtd = kzalloc_obj(struct mtd_info, GFP_KERNEL);
+ mtd = kzalloc_obj(struct mtd_info);
if (!mtd)
break;
- priv = kzalloc_obj(struct mypriv, GFP_KERNEL);
+ priv = kzalloc_obj(struct mypriv);
if (!priv) {
kfree(mtd);
break;
diff --git a/drivers/mtd/devices/slram.c b/drivers/mtd/devices/slram.c
index 1ac94e837f26..69cb63d99f57 100644
--- a/drivers/mtd/devices/slram.c
+++ b/drivers/mtd/devices/slram.c
@@ -135,17 +135,17 @@ static int register_device(char *name, unsigned long start, unsigned long length
curmtd = &(*curmtd)->next;
}
- *curmtd = kmalloc_obj(slram_mtd_list_t, GFP_KERNEL);
+ *curmtd = kmalloc_obj(slram_mtd_list_t);
if (!(*curmtd)) {
E("slram: Cannot allocate new MTD device.\n");
return(-ENOMEM);
}
- (*curmtd)->mtdinfo = kzalloc_obj(struct mtd_info, GFP_KERNEL);
+ (*curmtd)->mtdinfo = kzalloc_obj(struct mtd_info);
(*curmtd)->next = NULL;
if ((*curmtd)->mtdinfo) {
(*curmtd)->mtdinfo->priv =
- kzalloc_obj(slram_priv_t, GFP_KERNEL);
+ kzalloc_obj(slram_priv_t);
if (!(*curmtd)->mtdinfo->priv) {
kfree((*curmtd)->mtdinfo);