Skip to content

Commit

Permalink
drivers/mmc/core/host.c: kmalloc + memset conversion to kzalloc
Browse files Browse the repository at this point in the history
 drivers/mmc/core/host.c | 3509 -> 3457 (-52 bytes)
 drivers/mmc/core/host.o | 92400 -> 92136 (-264 bytes)

Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
  • Loading branch information
Mariusz Kozlowski authored and Pierre Ossman committed Aug 23, 2007
1 parent 733cb1e commit be760a9
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/mmc/core/host.c
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,10 @@ struct mmc_host *mmc_alloc_host(int extra, struct device *dev)
{
struct mmc_host *host;

host = kmalloc(sizeof(struct mmc_host) + extra, GFP_KERNEL);
host = kzalloc(sizeof(struct mmc_host) + extra, GFP_KERNEL);
if (!host)
return NULL;

memset(host, 0, sizeof(struct mmc_host) + extra);

host->parent = dev;
host->class_dev.parent = dev;
host->class_dev.class = &mmc_host_class;
Expand Down

0 comments on commit be760a9

Please sign in to comment.