From patchwork Tue Feb 13 11:20:46 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiri Slaby X-Patchwork-Id: 200381 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:bc8a:b0:106:860b:bbdd with SMTP id dn10csp468065dyb; Tue, 13 Feb 2024 03:21:59 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXewUfSrOI5TltscSIWnnNjD+Qc2Jzao40d+aCoqKpLewDrzBPyYT5BQZ8Mq2JSUnU1oG/6Nokwrarj0KX2YvCqoGMAWQ== X-Google-Smtp-Source: AGHT+IHbRRn4ByK8iF8L0Ejhi9RHYtkaYTCt3fQCQ53OJYCsMJYUdJ4Oqr2QwiLy8NkDRVTYlMZE X-Received: by 2002:a05:6122:181e:b0:4c0:7753:231 with SMTP id ay30-20020a056122181e00b004c077530231mr6304888vkb.13.1707823319400; Tue, 13 Feb 2024 03:21:59 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707823319; cv=pass; d=google.com; s=arc-20160816; b=FdgkucKXnBUxn+pcR4O05V5/n2RuehzVQMx+p2llG2eGFlMMLFYe6P+Ww36ZTQDRLj LgEXn1LeEcSkQ235Jz5Fj7oSKI5Cp0/7RPcZiIc4ORPaaqcQZZvEdIxUbmAosWem4QzS TmDt9R0Vr2xRMXtfx2rL+BBRzKNT7NEXBag6r/XO6CYnhJpS34P9huAHpIoMjCesH/7A RPWF/4FpyJd2rLb/GypuuPMm0ooGzwKIZexwenvt1pKgLx19Hl0J5CQVSpeceJe4Lx5+ XwzuhLecSIvh01z0hUIPGT68lCeDK8lzBf3Op2NmbUvj5uLckC2DG+AYpgNVq9+OO56W 5WIA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=6HpWGQjY40E/bzBGDk5EafmdTAcragUWE4L/7by75Qw=; fh=Hpe8x3F7jDm0rJNKydpUywJHdkrkiZnnEju96pOs/9I=; b=zAzbYXkprZybpFnsb1cabenXNQZlp+5zyTVM0+CuZAW6hjH3Uo+EPrQuRYJLepAj7+ gmV0Zob9wSW5AHtkMxES8F63MNb1ZUIOLn80qDVfsOESnusMCRkKpAWcUTzNwt708CUT 4Bk4gsAVT37S7Ct1sCoUcEym7QVnZJZ4zh0LVd9C/AGtnUNTVoxhCnTsIDvFk5aJ9JN3 T53qZG2mDiqONMbWBrf6w3qBA6Xhx47f38CVqSe1TgI9TBL3Y7lUJG15U+scNTO0ixcO 86zchaBSRmPh/BVNCALIH0un+isLsWsgk/3A+f3ck9fG/sD5DObqhBJ3ndfxtypGqIam 2RhA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=u1nKU+9s; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-63419-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-63419-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Forwarded-Encrypted: i=2; AJvYcCXnCuFpRHCV1Df93kKtiJaGIH9ftIsrrMv/pX7ateExD/vTTm53PmxHfCMImhlZGedrAXtutCtGhk89+vy/SnEGLa95QQ== Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id 10-20020a056214202a00b0068c7a7ed57csi2574466qvf.540.2024.02.13.03.21.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Feb 2024 03:21:59 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-63419-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=u1nKU+9s; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-63419-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-63419-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 13CC91C22A4B for ; Tue, 13 Feb 2024 11:21:59 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B676439FE1; Tue, 13 Feb 2024 11:21:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="u1nKU+9s" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3D6DE3838B; Tue, 13 Feb 2024 11:21:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707823265; cv=none; b=tNZzLFEU80tsxfkJj6+pMx7LA3SqLpLZsrwQI3ayiIOSjmpGWmgpVFcTsu/T7cHLin5f3QkdEGZjRt4bZD7qXNBmlB143lmdzFyrwvxV8FZMz+7wdVKgGw/JxCkzjC+bwpqPCv4QhgR+QNg1d/1AOpbj14lJci1UzVSJkpJr9/Q= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707823265; c=relaxed/simple; bh=iSGTy1weM6BB1E4whQVWIFf+UuG8A2NUShVr01qyUoU=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=iW3p8/4P1XhjZCSNICBv7E2L+Yi4ZiGDexWLWh3GYkYyyzvBtD2tqDSo7BiyVaLQDf7rCOL3/FE4MZLZeZM/PTUZNRTf7236mjOlPFhvZtV2MzC/gzd0r5A3i2J681uK72Y2pqUw6lwC4wco8N28PG/vaU0Tfjlf70FvlxLfRSc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=u1nKU+9s; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id CA149C433B1; Tue, 13 Feb 2024 11:21:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1707823263; bh=iSGTy1weM6BB1E4whQVWIFf+UuG8A2NUShVr01qyUoU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=u1nKU+9sfquXXqkd6qyBkxjqnS0AFPguGvx53BQw02NAU5I1tvz2rW3d556C6cgFw AU508gCgj2+AtwMbOOCE0vH/JA2enqcK8wKQvxQKnRA0NmW4/H6s+K/3XYV8kCt4X4 QnyLN+P0JeTN9aIcPLIVMylj7lBJj5ErR1b7ESy10sB7sABhoAnEscJ81FKfBUnSY8 Jf/nzgAuJFteIOVjviatJdFz1sFnO5Hsu6wqvRtPveopFwOm606da6k2qSbbYvanYx snqKquOrmW58aMT6H9jXkjO/Zf3lv7fY09AVSh5Tbpg0DRuwtjv6jmpJ1V/zNg16/g hBbq7yqgs2yvg== From: "Jiri Slaby (SUSE)" To: bp@alien8.de Cc: linux-kernel@vger.kernel.org, "Jiri Slaby (SUSE)" , Douglas Thompson , Tony Luck , James Morse , Mauro Carvalho Chehab , Robert Richter , linux-edac@vger.kernel.org Subject: [PATCH 2/7] EDAC/device: Remove edac_dev_sysfs_block_attribute::{block,value} Date: Tue, 13 Feb 2024 12:20:46 +0100 Message-ID: <20240213112051.27715-3-jirislaby@kernel.org> X-Mailer: git-send-email 2.43.1 In-Reply-To: <20240213112051.27715-1-jirislaby@kernel.org> References: <20240213112051.27715-1-jirislaby@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790782544980021080 X-GMAIL-MSGID: 1790782544980021080 It's unused. And it never was since its addition in fd309a9d8e63e (drivers/edac: fix leaf sysfs attribute). Drop it. Found by https://github.com/jirislaby/clang-struct. Signed-off-by: Jiri Slaby (SUSE) Cc: Douglas Thompson Cc: Borislav Petkov Cc: Tony Luck Cc: James Morse Cc: Mauro Carvalho Chehab Cc: Robert Richter Cc: linux-edac@vger.kernel.org --- drivers/edac/edac_device.c | 2 -- drivers/edac/edac_device.h | 6 ------ 2 files changed, 8 deletions(-) diff --git a/drivers/edac/edac_device.c b/drivers/edac/edac_device.c index 0689e1510721..0e18729111d4 100644 --- a/drivers/edac/edac_device.c +++ b/drivers/edac/edac_device.c @@ -162,8 +162,6 @@ edac_device_alloc_ctl_info(unsigned pvt_sz, char *dev_name, unsigned nr_instance attrib->show = attrib_spec[attr].show; attrib->store = attrib_spec[attr].store; - attrib->block = blk; /* up link */ - edac_dbg(4, "alloc-attrib=%p attrib_name='%s' attrib-spec=%p spec-name=%s\n", attrib, attrib->attr.name, &attrib_spec[attr], diff --git a/drivers/edac/edac_device.h b/drivers/edac/edac_device.h index 7db22a4c83ef..c4704b5b1e9f 100644 --- a/drivers/edac/edac_device.h +++ b/drivers/edac/edac_device.h @@ -99,18 +99,12 @@ struct edac_dev_sysfs_attribute { * can have an array of the following. The show and store functions * will be filled in with the show/store function in the * low level driver. - * - * The 'value' field will be the actual value field used for - * counting */ struct edac_dev_sysfs_block_attribute { struct attribute attr; ssize_t (*show)(struct kobject *, struct attribute *, char *); ssize_t (*store)(struct kobject *, struct attribute *, const char *, size_t); - struct edac_device_block *block; - - unsigned int value; }; /* device block control structure */