summaryrefslogtreecommitdiffstats
path: root/drivers/vme/bridges
diff options
context:
space:
mode:
authorMarkus Elfring <elfring@users.sourceforge.net>2017-08-25 11:10:07 +0200
committerMartyn Welch <martyn.welch@collabora.co.uk>2017-10-13 21:32:03 +0100
commit97660957fb5318d76a680a1b6cfb7b998bfa3723 (patch)
tree3dddb3c62d3778b6dc7cc361cf7b07eafc2a374f /drivers/vme/bridges
parent8d97931740cff8f4eea62f5690e470444905db60 (diff)
downloadlinux-97660957fb5318d76a680a1b6cfb7b998bfa3723.tar.bz2
vme: tsi148: Delete nine error messages for a failed memory allocation
Omit extra messages for a memory allocation failure in these functions. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Martyn Welch <martyn@welchs.me.uk>
Diffstat (limited to 'drivers/vme/bridges')
-rw-r--r--drivers/vme/bridges/vme_tsi148.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/drivers/vme/bridges/vme_tsi148.c b/drivers/vme/bridges/vme_tsi148.c
index fc1b634b969a..fb91fddc6312 100644
--- a/drivers/vme/bridges/vme_tsi148.c
+++ b/drivers/vme/bridges/vme_tsi148.c
@@ -751,8 +751,6 @@ static int tsi148_alloc_resource(struct vme_master_resource *image,
if (image->bus_resource.name == NULL) {
image->bus_resource.name = kmalloc(VMENAMSIZ+3, GFP_ATOMIC);
if (image->bus_resource.name == NULL) {
- dev_err(tsi148_bridge->parent, "Unable to allocate "
- "memory for resource name\n");
retval = -ENOMEM;
goto err_name;
}
@@ -1643,8 +1641,6 @@ static int tsi148_dma_list_add(struct vme_dma_list *list,
/* Descriptor must be aligned on 64-bit boundaries */
entry = kmalloc(sizeof(struct tsi148_dma_entry), GFP_KERNEL);
if (entry == NULL) {
- dev_err(tsi148_bridge->parent, "Failed to allocate memory for "
- "dma resource structure\n");
retval = -ENOMEM;
goto err_mem;
}
@@ -2296,8 +2292,6 @@ static int tsi148_probe(struct pci_dev *pdev, const struct pci_device_id *id)
*/
tsi148_bridge = kzalloc(sizeof(struct vme_bridge), GFP_KERNEL);
if (tsi148_bridge == NULL) {
- dev_err(&pdev->dev, "Failed to allocate memory for device "
- "structure\n");
retval = -ENOMEM;
goto err_struct;
}
@@ -2305,8 +2299,6 @@ static int tsi148_probe(struct pci_dev *pdev, const struct pci_device_id *id)
tsi148_device = kzalloc(sizeof(struct tsi148_driver), GFP_KERNEL);
if (tsi148_device == NULL) {
- dev_err(&pdev->dev, "Failed to allocate memory for device "
- "structure\n");
retval = -ENOMEM;
goto err_driver;
}
@@ -2373,8 +2365,6 @@ static int tsi148_probe(struct pci_dev *pdev, const struct pci_device_id *id)
tsi148_device->flush_image =
kmalloc(sizeof(struct vme_master_resource), GFP_KERNEL);
if (tsi148_device->flush_image == NULL) {
- dev_err(&pdev->dev, "Failed to allocate memory for "
- "flush resource structure\n");
retval = -ENOMEM;
goto err_master;
}
@@ -2392,8 +2382,6 @@ static int tsi148_probe(struct pci_dev *pdev, const struct pci_device_id *id)
master_image = kmalloc(sizeof(struct vme_master_resource),
GFP_KERNEL);
if (master_image == NULL) {
- dev_err(&pdev->dev, "Failed to allocate memory for "
- "master resource structure\n");
retval = -ENOMEM;
goto err_master;
}
@@ -2421,8 +2409,6 @@ static int tsi148_probe(struct pci_dev *pdev, const struct pci_device_id *id)
slave_image = kmalloc(sizeof(struct vme_slave_resource),
GFP_KERNEL);
if (slave_image == NULL) {
- dev_err(&pdev->dev, "Failed to allocate memory for "
- "slave resource structure\n");
retval = -ENOMEM;
goto err_slave;
}
@@ -2445,8 +2431,6 @@ static int tsi148_probe(struct pci_dev *pdev, const struct pci_device_id *id)
dma_ctrlr = kmalloc(sizeof(struct vme_dma_resource),
GFP_KERNEL);
if (dma_ctrlr == NULL) {
- dev_err(&pdev->dev, "Failed to allocate memory for "
- "dma resource structure\n");
retval = -ENOMEM;
goto err_dma;
}
@@ -2467,8 +2451,6 @@ static int tsi148_probe(struct pci_dev *pdev, const struct pci_device_id *id)
/* Add location monitor to list */
lm = kmalloc(sizeof(struct vme_lm_resource), GFP_KERNEL);
if (lm == NULL) {
- dev_err(&pdev->dev, "Failed to allocate memory for "
- "location monitor resource structure\n");
retval = -ENOMEM;
goto err_lm;
}