aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/bluetooth/hci_ldisc.c
diff options
context:
space:
mode:
authorDeepak Saxena <dsaxena@plexity.net>2005-11-07 04:01:26 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2005-11-07 10:54:00 -0500
commit089b1dbbde28f0f641c20beabba28fa89ab4fab9 (patch)
treed95a59688897569f2aa875ec5a9576caaedfc2cc /drivers/bluetooth/hci_ldisc.c
parentf5e3c2faa20615e900ab26bd957f898400435924 (diff)
[PATCH] bluetooth: kmalloc + memset -> kzalloc conversion
Signed-off-by: Deepak Saxena <dsaxena@plexity.net> Cc: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/bluetooth/hci_ldisc.c')
-rw-r--r--drivers/bluetooth/hci_ldisc.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/bluetooth/hci_ldisc.c b/drivers/bluetooth/hci_ldisc.c
index 4a775f6ea390..573ff6c1be5f 100644
--- a/drivers/bluetooth/hci_ldisc.c
+++ b/drivers/bluetooth/hci_ldisc.c
@@ -272,13 +272,11 @@ static int hci_uart_tty_open(struct tty_struct *tty)
272 if (hu) 272 if (hu)
273 return -EEXIST; 273 return -EEXIST;
274 274
275 if (!(hu = kmalloc(sizeof(struct hci_uart), GFP_KERNEL))) { 275 if (!(hu = kzalloc(sizeof(struct hci_uart), GFP_KERNEL))) {
276 BT_ERR("Can't allocate controll structure"); 276 BT_ERR("Can't allocate controll structure");
277 return -ENFILE; 277 return -ENFILE;
278 } 278 }
279 279
280 memset(hu, 0, sizeof(struct hci_uart));
281
282 tty->disc_data = hu; 280 tty->disc_data = hu;
283 hu->tty = tty; 281 hu->tty = tty;
284 282