Skip to content

Commit

Permalink
dm: bow, req-crypt: Remove SECTOR_SIZE macro definition
Browse files Browse the repository at this point in the history
After commit d24c407 from v4.9.236, one will expect following two warnings
appear during compilation:

  /mnt/ssd/kernels/mido-4.9/drivers/md/dm-req-crypt.c:54:9: warning:
        'SECTOR_SIZE' macro redefined [-Wmacro-redefined]
  #define SECTOR_SIZE 512
          ^
  /mnt/ssd/kernels/mido-4.9/include/linux/blkdev.h:873:9: note: previous
        definition is here
  #define SECTOR_SIZE (1 << SECTOR_SHIFT)
          ^
  1 warning generated.

  /mnt/ssd/kernels/mido-4.9/drivers/md/dm-bow.c:15:9: warning: 'SECTOR_SIZE'
        macro redefined [-Wmacro-redefined]
  #define SECTOR_SIZE 512
          ^
  /mnt/ssd/kernels/mido-4.9/include/linux/blkdev.h:873:9: note: previous
        definition is here
  #define SECTOR_SIZE (1 << SECTOR_SHIFT)
          ^
  1 warning generated.

Since it has been moved globally, just remove local definition from these
drivers.

Signed-off-by: Albert I <[email protected]>
  • Loading branch information
krasCGQ committed Sep 14, 2020
1 parent 03f7919 commit 7924438
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 2 deletions.
1 change: 0 additions & 1 deletion drivers/md/dm-bow.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#include <linux/module.h>

#define DM_MSG_PREFIX "bow"
#define SECTOR_SIZE 512

struct log_entry {
u64 source;
Expand Down
1 change: 0 additions & 1 deletion drivers/md/dm-req-crypt.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@
#define KEY_SIZE_XTS 32
#define AES_XTS_IV_LEN 16
#define MAX_MSM_ICE_KEY_LUT_SIZE 32
#define SECTOR_SIZE 512
#define MIN_CRYPTO_TRANSFER_SIZE (4 * 1024)

#define DM_REQ_CRYPT_ERROR -1
Expand Down

0 comments on commit 7924438

Please sign in to comment.