From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752286AbbG0MPc (ORCPT ); Mon, 27 Jul 2015 08:15:32 -0400 Received: from mx1.redhat.com ([209.132.183.28]:40140 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750789AbbG0MPb (ORCPT ); Mon, 27 Jul 2015 08:15:31 -0400 Date: Mon, 27 Jul 2015 08:15:29 -0400 From: Mike Snitzer To: Colin King Cc: Alasdair Kergon , dm-devel@redhat.com, Neil Brown , linux-raid@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: dm cache: fix alloc_bitset check that always evaluates as false Message-ID: <20150727121529.GC2312@redhat.com> References: <1437666479-24633-1-git-send-email-colin.king@canonical.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1437666479-24633-1-git-send-email-colin.king@canonical.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jul 23 2015 at 11:47P -0400, Colin King wrote: > From: Colin Ian King > > static analysis by cppcheck has found a check on alloc_bitset that > always evaluates as false and hence never finds an allocation failure: > > [drivers/md/dm-cache-policy-smq.c:1689]: (warning) Logical conjunction > always evaluates to false: !EXPR && EXPR. > > Fix this by removing the incorrect mq->cache_hit_bits check > > Signed-off-by: Colin Ian King Applied for 4.2-rc5 inclussion, thanks: https://git.kernel.org/cgit/linux/kernel/git/device-mapper/linux-dm.git/commit/?h=for-next&id=134bf30c06f057d6b8d90132e8f8b3cd2be79572