1. 30 Nov, 2018 1 commit
  2. 22 Aug, 2018 1 commit
    • Christophe Leroy's avatar
      lib/test_hexdump.c: fix failure on big endian cpu · de9df399
      Christophe Leroy authored
      On a big endian cpu, test_hexdump fails as follows.  The logs show that
      bytes are expected in reversed order.
      
        [...]
        test_hexdump: Len: 24 buflen: 130 strlen: 97
        test_hexdump: Result: 97 'be32db7b 0a1893b2 70bac424 7d83349b a69c31ad 9c0face9                    .2.{....p..$}.4...1.....'
        test_hexdump: Expect: 97 '7bdb32be b293180a 24c4ba70 9b34837d ad319ca6 e9ac0f9c                    .2.{....p..$}.4...1.....'
        test_hexdump: Len: 8 buflen: 130 strlen: 77
        test_hexdump: Result: 77 'be32db7b0a1893b2                                                     .2.{....'
        test_hexdump: Expect: 77 'b293180a7bdb32be                                                     .2.{....'
        test_hexdump: Len: 6 buflen: 131 strlen: 87
        test_hexdump: Result: 87 'be32 db7b 0a18                                                                   .2.{..'
        test_hexdump: Expect: 87 '32be 7bdb 180a                                                                   .2.{..'
        test_hexdump: Len: 24 buflen: 131 strlen: 97
        test_hexdump: Result: 97 'be32db7b 0a1893b2 70bac424 7d83349b a69c31ad 9c0face9                    .2.{....p..$}.4...1.....'
        test_hexdump: Expect: 97 '7bdb32be b293180a 24c4ba70 9b34837d ad319ca6 e9ac0f9c                    .2.{....p..$}.4...1.....'
        test_hexdump: Len: 32 buflen: 131 strlen: 101
        test_hexdump: Result: 101 'be32db7b0a1893b2 70bac4247d83349b a69c31ad9c0face9 4cd1199943b1af0c  .2.{....p..$}.4...1.....L...C...'
        test_hexdump: Expect: 101 'b293180a7bdb32be 9b34837d24c4ba70 e9ac0f9cad319ca6 0cafb1439919d14c  .2.{....p..$}.4...1.....L...C...'
        test_hexdump: failed 801 out of 1184 tests
      
      This patch fixes it.
      
      Link: http://lkml.kernel.org/r/f3112437f62c2f48300535510918e8be1dceacfb.1533610877.git.christophe.leroy@c-s.fr
      Fixes: 64d1d77a ("hexdump: introduce test suite")
      Signed-off-by: default avatarChristophe Leroy <christophe.leroy@c-s.fr>
      Reviewed-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Cc: rashmica <rashmicy@gmail.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      de9df399
  3. 21 Jan, 2016 9 commits
  4. 26 Jun, 2015 1 commit
  5. 19 Apr, 2015 1 commit
    • Linus Torvalds's avatar
      hexdump: avoid warning in test function · 17974c05
      Linus Torvalds authored
      The test_data_1_le[] array is a const array of const char *.  To avoid
      dropping any const information, we need to use "const char * const *",
      not just "const char **".
      
      I'm not sure why the different test arrays end up having different
      const'ness, but let's make the pointer we use to traverse them as const
      as possible, since we modify neither the array of pointers _or_ the
      pointers we find in the array.
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      17974c05
  6. 15 Apr, 2015 1 commit
  7. 13 Feb, 2015 2 commits