Skip to content

Commit

Permalink
mtd: cfi_util: do not printk if no extended query table
Browse files Browse the repository at this point in the history
Signed-off-by: Guillaume LECERF <glecerf@gmail.com>
Reviewed-by: Wolfram Sang <w.sang@pengutronix.de>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
  • Loading branch information
Guillaume LECERF authored and David Woodhouse committed May 14, 2010
1 parent 5a0563f commit 087444d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/mtd/chips/cfi_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,11 @@ __xipram cfi_read_pri(struct map_info *map, __u16 adr, __u16 size, const char* n
int i;
struct cfi_extquery *extp = NULL;

printk(" %s Extended Query Table at 0x%4.4X\n", name, adr);
if (!adr)
goto out;

printk(KERN_INFO "%s Extended Query Table at 0x%4.4X\n", name, adr);

extp = kmalloc(size, GFP_KERNEL);
if (!extp) {
printk(KERN_ERR "Failed to allocate memory\n");
Expand Down

0 comments on commit 087444d

Please sign in to comment.