aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-iop3xx
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-iop3xx')
-rw-r--r--arch/arm/mach-iop3xx/iop331-setup.c4
-rw-r--r--arch/arm/mach-iop3xx/iq31244-pci.c4
-rw-r--r--arch/arm/mach-iop3xx/iq80321-pci.c4
-rw-r--r--arch/arm/mach-iop3xx/iq80331-pci.c4
-rw-r--r--arch/arm/mach-iop3xx/iq80332-pci.c4
5 files changed, 6 insertions, 14 deletions
diff --git a/arch/arm/mach-iop3xx/iop331-setup.c b/arch/arm/mach-iop3xx/iop331-setup.c
index 2d6abe5be14d..7b7b6eea3846 100644
--- a/arch/arm/mach-iop3xx/iop331-setup.c
+++ b/arch/arm/mach-iop3xx/iop331-setup.c
@@ -103,7 +103,7 @@ static struct plat_serial8250_port iop33x_uart1_data[] = {
103 103
104static struct platform_device iop33x_uart0 = { 104static struct platform_device iop33x_uart0 = {
105 .name = "serial8250", 105 .name = "serial8250",
106 .id = 0, 106 .id = PLAT8250_DEV_PLATFORM,
107 .dev.platform_data = iop33x_uart0_data, 107 .dev.platform_data = iop33x_uart0_data,
108 .num_resources = 2, 108 .num_resources = 2,
109 .resource = iop33x_uart0_resources, 109 .resource = iop33x_uart0_resources,
@@ -111,7 +111,7 @@ static struct platform_device iop33x_uart0 = {
111 111
112static struct platform_device iop33x_uart1 = { 112static struct platform_device iop33x_uart1 = {
113 .name = "serial8250", 113 .name = "serial8250",
114 .id = 1, 114 .id = PLAT8250_DEV_PLATFORM1,
115 .dev.platform_data = iop33x_uart1_data, 115 .dev.platform_data = iop33x_uart1_data,
116 .num_resources = 2, 116 .num_resources = 2,
117 .resource = iop33x_uart1_resources, 117 .resource = iop33x_uart1_resources,
diff --git a/arch/arm/mach-iop3xx/iq31244-pci.c b/arch/arm/mach-iop3xx/iq31244-pci.c
index c6a973ba8fc6..f3c6413fa5bd 100644
--- a/arch/arm/mach-iop3xx/iq31244-pci.c
+++ b/arch/arm/mach-iop3xx/iq31244-pci.c
@@ -74,12 +74,10 @@ static int iq31244_setup(int nr, struct pci_sys_data *sys)
74 if(nr != 0) 74 if(nr != 0)
75 return 0; 75 return 0;
76 76
77 res = kmalloc(sizeof(struct resource) * 2, GFP_KERNEL); 77 res = kzalloc(sizeof(struct resource) * 2, GFP_KERNEL);
78 if (!res) 78 if (!res)
79 panic("PCI: unable to alloc resources"); 79 panic("PCI: unable to alloc resources");
80 80
81 memset(res, 0, sizeof(struct resource) * 2);
82
83 res[0].start = IOP321_PCI_LOWER_IO_VA; 81 res[0].start = IOP321_PCI_LOWER_IO_VA;
84 res[0].end = IOP321_PCI_UPPER_IO_VA; 82 res[0].end = IOP321_PCI_UPPER_IO_VA;
85 res[0].name = "IQ31244 PCI I/O Space"; 83 res[0].name = "IQ31244 PCI I/O Space";
diff --git a/arch/arm/mach-iop3xx/iq80321-pci.c b/arch/arm/mach-iop3xx/iq80321-pci.c
index 802f6d091b75..d9758d3f6e7f 100644
--- a/arch/arm/mach-iop3xx/iq80321-pci.c
+++ b/arch/arm/mach-iop3xx/iq80321-pci.c
@@ -68,12 +68,10 @@ static int iq80321_setup(int nr, struct pci_sys_data *sys)
68 if(nr != 0) 68 if(nr != 0)
69 return 0; 69 return 0;
70 70
71 res = kmalloc(sizeof(struct resource) * 2, GFP_KERNEL); 71 res = kzalloc(sizeof(struct resource) * 2, GFP_KERNEL);
72 if (!res) 72 if (!res)
73 panic("PCI: unable to alloc resources"); 73 panic("PCI: unable to alloc resources");
74 74
75 memset(res, 0, sizeof(struct resource) * 2);
76
77 res[0].start = IOP321_PCI_LOWER_IO_VA; 75 res[0].start = IOP321_PCI_LOWER_IO_VA;
78 res[0].end = IOP321_PCI_UPPER_IO_VA; 76 res[0].end = IOP321_PCI_UPPER_IO_VA;
79 res[0].name = "IQ80321 PCI I/O Space"; 77 res[0].name = "IQ80321 PCI I/O Space";
diff --git a/arch/arm/mach-iop3xx/iq80331-pci.c b/arch/arm/mach-iop3xx/iq80331-pci.c
index 654e450a1311..40d861002492 100644
--- a/arch/arm/mach-iop3xx/iq80331-pci.c
+++ b/arch/arm/mach-iop3xx/iq80331-pci.c
@@ -64,12 +64,10 @@ static int iq80331_setup(int nr, struct pci_sys_data *sys)
64 if(nr != 0) 64 if(nr != 0)
65 return 0; 65 return 0;
66 66
67 res = kmalloc(sizeof(struct resource) * 2, GFP_KERNEL); 67 res = kzalloc(sizeof(struct resource) * 2, GFP_KERNEL);
68 if (!res) 68 if (!res)
69 panic("PCI: unable to alloc resources"); 69 panic("PCI: unable to alloc resources");
70 70
71 memset(res, 0, sizeof(struct resource) * 2);
72
73 res[0].start = IOP331_PCI_LOWER_IO_VA; 71 res[0].start = IOP331_PCI_LOWER_IO_VA;
74 res[0].end = IOP331_PCI_UPPER_IO_VA; 72 res[0].end = IOP331_PCI_UPPER_IO_VA;
75 res[0].name = "IQ80331 PCI I/O Space"; 73 res[0].name = "IQ80331 PCI I/O Space";
diff --git a/arch/arm/mach-iop3xx/iq80332-pci.c b/arch/arm/mach-iop3xx/iq80332-pci.c
index 65951ffe4631..afc0676318e4 100644
--- a/arch/arm/mach-iop3xx/iq80332-pci.c
+++ b/arch/arm/mach-iop3xx/iq80332-pci.c
@@ -70,12 +70,10 @@ static int iq80332_setup(int nr, struct pci_sys_data *sys)
70 if(nr != 0) 70 if(nr != 0)
71 return 0; 71 return 0;
72 72
73 res = kmalloc(sizeof(struct resource) * 2, GFP_KERNEL); 73 res = kzalloc(sizeof(struct resource) * 2, GFP_KERNEL);
74 if (!res) 74 if (!res)
75 panic("PCI: unable to alloc resources"); 75 panic("PCI: unable to alloc resources");
76 76
77 memset(res, 0, sizeof(struct resource) * 2);
78
79 res[0].start = IOP331_PCI_LOWER_IO_VA; 77 res[0].start = IOP331_PCI_LOWER_IO_VA;
80 res[0].end = IOP331_PCI_UPPER_IO_VA; 78 res[0].end = IOP331_PCI_UPPER_IO_VA;
81 res[0].name = "IQ80332 PCI I/O Space"; 79 res[0].name = "IQ80332 PCI I/O Space";