aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/serial/8250_pci.c
diff options
context:
space:
mode:
authorBurman Yan <yan_952@hotmail.com>2007-02-14 03:33:07 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-14 11:09:52 -0500
commit8f31bb39ec2a5622974666c72257e74c22492602 (patch)
tree48f38c994f02c8699fe2a69599e8cc1bc8d36ea8 /drivers/serial/8250_pci.c
parent3689a0ec60bc8f56cc372c1dfa0d89dab48f7c9c (diff)
[PATCH] serial: replace kmalloc+memset with kzalloc
Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/serial/8250_pci.c')
-rw-r--r--drivers/serial/8250_pci.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/serial/8250_pci.c b/drivers/serial/8250_pci.c
index a2dac378bda9..2989228ed701 100644
--- a/drivers/serial/8250_pci.c
+++ b/drivers/serial/8250_pci.c
@@ -1628,7 +1628,7 @@ pciserial_init_ports(struct pci_dev *dev, struct pciserial_board *board)
1628 nr_ports = rc; 1628 nr_ports = rc;
1629 } 1629 }
1630 1630
1631 priv = kmalloc(sizeof(struct serial_private) + 1631 priv = kzalloc(sizeof(struct serial_private) +
1632 sizeof(unsigned int) * nr_ports, 1632 sizeof(unsigned int) * nr_ports,
1633 GFP_KERNEL); 1633 GFP_KERNEL);
1634 if (!priv) { 1634 if (!priv) {
@@ -1636,9 +1636,6 @@ pciserial_init_ports(struct pci_dev *dev, struct pciserial_board *board)
1636 goto err_deinit; 1636 goto err_deinit;
1637 } 1637 }
1638 1638
1639 memset(priv, 0, sizeof(struct serial_private) +
1640 sizeof(unsigned int) * nr_ports);
1641
1642 priv->dev = dev; 1639 priv->dev = dev;
1643 priv->quirk = quirk; 1640 priv->quirk = quirk;
1644 1641