From 363f844cc2dc04f3581bd839537a574ca2484420 Mon Sep 17 00:00:00 2001 From: Eric Biggers Date: Wed, 8 Sep 2021 20:30:31 -0700 Subject: [PATCH] ANDROID: dm-bow: handle STATUSTYPE_IMA MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix the following compiler warning caused by STATUSTYPE_IMA being added upstream: drivers/md/dm-bow.c: In function ‘dm_bow_status’: drivers/md/dm-bow.c:1239:2: warning: enumeration value ‘STATUSTYPE_IMA’ not handled in switch [-Wswitch] 1239 | switch (type) { | ^~~~~~ Until IMA data is defined for this target (currently there is no need to do so), the right thing to do is to just return an empty string. This should be folded into ANDROID-dm-bow-Add-dm-bow-feature.patch. Bug: 129280212 Fixes: bc2f6edebd94 ("Merge 9e9fb7655ed5 ("Merge tag 'net-next-5.15' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next") into android-mainline") Change-Id: I8b0e7c9d67f20071cdad8e7cb6940a9e35623e31 Signed-off-by: Eric Biggers --- drivers/md/dm-bow.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/md/dm-bow.c b/drivers/md/dm-bow.c index 0731b8e6d5ee..43bca2e60d4d 100644 --- a/drivers/md/dm-bow.c +++ b/drivers/md/dm-bow.c @@ -1238,6 +1238,7 @@ static void dm_bow_status(struct dm_target *ti, status_type_t type, { switch (type) { case STATUSTYPE_INFO: + case STATUSTYPE_IMA: if (maxlen) result[0] = 0; break;