Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp407335pxb; Wed, 3 Mar 2021 06:23:22 -0800 (PST) X-Google-Smtp-Source: ABdhPJxjelxjPW77AuuR2EwCzwaKOotbJXMx+xzJnaLKwjrW3BSPM9nCdQhPDAZOTUfxWdUBSxg6 X-Received: by 2002:a17:906:684b:: with SMTP id a11mr17030223ejs.329.1614781402738; Wed, 03 Mar 2021 06:23:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614781402; cv=none; d=google.com; s=arc-20160816; b=IBsJsFB1mr5D9awrnL9cne46x0LZD1HFA4Hh35BtpYzZADyjWWaaxkjsToXXKDPSYE AHhmzdIKt/cypXJSyx2GMs8+yIe2NPASE1allapXujZ2Fl72XjEV4xX9d9nEMI5O8JpM gSgCDtdbNhSWxFBm188QRIMzVKWcZ+CxJz/sPIneLm1PeE/o2kJmgv8dI4Gg89PuNzPq vJvW7Dd5SJmmHeVzv+jetuTafQmmT1HfircpLM6eTSL+dKkT89I4wD0x4xaT607RL+/D sjTl+DikS8n/OR/WBXASO4i2xs7f1PbgO8Yb+C0X2ALqHmLH7q+rhNw/WtK0Brs6RXAo I5IA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=+EXHWArtkTFixJ7S3ZImgIw5X7ql4zRrBfhIuPvkoC8=; b=sNiWY1JE3fUNdKD7vv5r6OcKuY+nfdDTGFKkC6cWjnY74Rs/BoZ38qt+61qVSyFDRt LtMCrWhchnS9jP/ljwavNEKLDx3yotIl7IVNolzTdG4rM3ZpTsgHgYdNmxE6B/uIjPvL qgpcGyrUVuBVSt/OkIrEte3q5PHn+dXEu2JJiLYF3r6tahvAkCI7QMOXs1Rh+9+DDDQb YIfUdp/MMsUGbg55hIMHAWIfz2iFmh6tRmcE5uRUUUKBQ47vPIOFrF7g0dYHtJYCYc7l ibTSbfe0azAH3aOy73M+Mf5eYqmGblQjs8qJupJ7qNtkqMdGkvbF3RWeabBrzo6OnuRF Q+GA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=0IMSQYwa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d11si15002534eje.586.2021.03.03.06.22.20; Wed, 03 Mar 2021 06:23:22 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=0IMSQYwa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244245AbhCAVXw (ORCPT + 99 others); Mon, 1 Mar 2021 16:23:52 -0500 Received: from mail.kernel.org ([198.145.29.99]:49744 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237789AbhCARQD (ORCPT ); Mon, 1 Mar 2021 12:16:03 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 3DE48614A7; Mon, 1 Mar 2021 16:46:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1614617193; bh=/urCMM9ZpFlUDciR4PbTj3F5bhuIcZh9BT+swyoBi1M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=0IMSQYwa2js/vyPTlfWXVqwhCQ17lWae50UPLVGQPFp5DvYH9ZtdxYCvCBVBz2DJD mmQZAIxJhPQc3vBSzHzC89xKAqpYXxm4m3zbz7wneu4hJiSFGPGsbQE76DoJY9AweT PgwcYDpy0MCyfG6VKThOHo0VTEjr1xXb4NDfWbRI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Nikos Tsironis , Ming-Hung Tsai , Mike Snitzer Subject: [PATCH 4.19 236/247] dm era: Use correct value size in equality function of writeset tree Date: Mon, 1 Mar 2021 17:14:16 +0100 Message-Id: <20210301161043.256433369@linuxfoundation.org> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210301161031.684018251@linuxfoundation.org> References: <20210301161031.684018251@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Nikos Tsironis commit 64f2d15afe7b336aafebdcd14cc835ecf856df4b upstream. Fix the writeset tree equality test function to use the right value size when comparing two btree values. Fixes: eec40579d84873 ("dm: add era target") Cc: stable@vger.kernel.org # v3.15+ Signed-off-by: Nikos Tsironis Reviewed-by: Ming-Hung Tsai Signed-off-by: Mike Snitzer Signed-off-by: Greg Kroah-Hartman --- drivers/md/dm-era-target.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/md/dm-era-target.c +++ b/drivers/md/dm-era-target.c @@ -388,7 +388,7 @@ static void ws_dec(void *context, const static int ws_eq(void *context, const void *value1, const void *value2) { - return !memcmp(value1, value2, sizeof(struct writeset_metadata)); + return !memcmp(value1, value2, sizeof(struct writeset_disk)); } /*----------------------------------------------------------------*/