]> git.sur5r.net Git - u-boot/blobdiff - drivers/mtd/ubi/attach.c
lib: Add hexdump
[u-boot] / drivers / mtd / ubi / attach.c
index 90fb74a5c966baeadf01e69c5ca6da9bb88d7e0f..b4ba339c804ccc1a6a5b95031661c43d024a8fa9 100644 (file)
@@ -1,8 +1,7 @@
+// SPDX-License-Identifier: GPL-2.0+
 /*
  * Copyright (c) International Business Machines Corp., 2006
  *
- * SPDX-License-Identifier:    GPL-2.0+
- *
  * Author: Artem Bityutskiy (Битюцкий Артём)
  */
 
@@ -790,7 +789,7 @@ static int check_corruption(struct ubi_device *ubi, struct ubi_vid_hdr *vid_hdr,
        ubi_dump_vid_hdr(vid_hdr);
        pr_err("hexdump of PEB %d offset %d, length %d",
               pnum, ubi->leb_start, ubi->leb_size);
-       ubi_dbg_print_hex_dump(KERN_DEBUG, "", DUMP_PREFIX_OFFSET, 32, 1,
+       ubi_dbg_print_hex_dump("", DUMP_PREFIX_OFFSET, 32, 1,
                               ubi->peb_buf, ubi->leb_size, 1);
        err = 1;
 
@@ -1205,8 +1204,7 @@ static void destroy_ai(struct ubi_attach_info *ai)
                }
        }
 
-       if (ai->aeb_slab_cache)
-               kmem_cache_destroy(ai->aeb_slab_cache);
+       kmem_cache_destroy(ai->aeb_slab_cache);
 
        kfree(ai);
 }