From patchwork Wed Dec 2 22:35:48 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felipe Balbi X-Patchwork-Id: 64369 X-Patchwork-Delegate: tony@atomide.com Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id nB2MaPlE025177 for ; Wed, 2 Dec 2009 22:36:26 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755908AbZLBWgR (ORCPT ); Wed, 2 Dec 2009 17:36:17 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755907AbZLBWgQ (ORCPT ); Wed, 2 Dec 2009 17:36:16 -0500 Received: from smtp.nokia.com ([192.100.105.134]:60611 "EHLO mgw-mx09.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755904AbZLBWgP (ORCPT ); Wed, 2 Dec 2009 17:36:15 -0500 Received: from esebh106.NOE.Nokia.com (esebh106.ntc.nokia.com [172.21.138.213]) by mgw-mx09.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id nB2Ma5t9023112; Wed, 2 Dec 2009 16:36:21 -0600 Received: from esebh102.NOE.Nokia.com ([172.21.138.183]) by esebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 3 Dec 2009 00:36:15 +0200 Received: from mgw-sa02.ext.nokia.com ([147.243.1.48]) by esebh102.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Thu, 3 Dec 2009 00:36:15 +0200 Received: from localhost.localdomain (esdhcp04340.research.nokia.com [172.21.43.40]) by mgw-sa02.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id nB2Ma5Fe032365; Thu, 3 Dec 2009 00:36:14 +0200 From: Felipe Balbi To: linux-omap@vger.kernel.org Cc: Tony Lindgren , Felipe Balbi Subject: [RFT/RFC/PATCH 06/10] cbus: switch to kzalloc Date: Thu, 3 Dec 2009 00:35:48 +0200 Message-Id: <1259793352-29864-7-git-send-email-felipe.balbi@nokia.com> X-Mailer: git-send-email 1.6.6.rc0 In-Reply-To: <1259793352-29864-1-git-send-email-felipe.balbi@nokia.com> References: <1259793352-29864-1-git-send-email-felipe.balbi@nokia.com> X-OriginalArrivalTime: 02 Dec 2009 22:36:15.0925 (UTC) FILETIME=[DBDE3E50:01CA739F] X-Nokia-AV: Clean Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org diff --git a/drivers/cbus/cbus.c b/drivers/cbus/cbus.c index c80cede..0bcc211 100644 --- a/drivers/cbus/cbus.c +++ b/drivers/cbus/cbus.c @@ -224,12 +224,10 @@ int __init cbus_bus_init(void) struct cbus_host *chost; int ret; - chost = kmalloc(sizeof (*chost), GFP_KERNEL); + chost = kzalloc(sizeof (*chost), GFP_KERNEL); if (chost == NULL) return -ENOMEM; - memset(chost, 0, sizeof (*chost)); - spin_lock_init(&chost->lock); /* REVISIT: Pass these from board-*.c files in platform_data */