From nobody Sun Feb 8 22:06:15 2026 Received: from smtpout-04.galae.net (smtpout-04.galae.net [185.171.202.116]) (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 B216F39449B for ; Wed, 4 Feb 2026 08:32:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.171.202.116 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770193950; cv=none; b=gSzdniKAU7jDg8J/MlRzRddjDwEy6GVwZpV/ayuM0uq8mJ6l1WqvmwADnUK1fxUyHk0lb1mOoTTor4XUnVuN9oqIP1DYy8KCI+kVvIqeKhuEWkQGAiT/pvjDr0lFrXFntzeQdPV70mKxknrRa561GxfxAy4kryxZnyIVBrtOmG8= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770193950; c=relaxed/simple; bh=oZAtESGQZtH5Gc9X3cmSQvtaXUHOXsWSJ0faQoOiao4=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=IZWdRduNewBGhUndz230mzxs+x8Md5D0S7zLIS6gY3JARbIuu7lLPt1FQHM/HYBRcFAggZN0BzIpfp1oJZhyfk7FFRRUBrNxsugQ2kLs8C4R1puMUGaw4BUBxEeYByG3Gbs9TTAOdnrE2DSSd2f2G0H6pkdx7QQbhp41HJPaxvI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=v5ZRduBK; arc=none smtp.client-ip=185.171.202.116 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="v5ZRduBK" Received: from smtpout-01.galae.net (smtpout-01.galae.net [212.83.139.233]) by smtpout-04.galae.net (Postfix) with ESMTPS id 8E5D5C24396; Wed, 4 Feb 2026 08:32:34 +0000 (UTC) Received: from mail.galae.net (mail.galae.net [212.83.136.155]) by smtpout-01.galae.net (Postfix) with ESMTPS id F08D560745; Wed, 4 Feb 2026 08:32:28 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 23ADA119A88EE; Wed, 4 Feb 2026 09:32:25 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=dkim; t=1770193948; h=from:subject:date:message-id:to:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:references; bh=IYfYtxqAQMooFvbBZW5NCWAmFPox9AqB9Ege5HL77z0=; b=v5ZRduBKWMMRuSKuRspNwIDtb7UudzHiBBXA3eaFDXAdK4Y2CcfMgctUqny75n40aMSI1M hzfqWzsO5mkhQVHC2hWmFCONPGAHZUjxKYeCytL6I+yiViC/yn096vy8PmHYbhs2kenbDC aFQvcGcJRUmXd67k6sRMol45gQlHx+A7Oirhb02Ie93ydFwcY13aahBd+Yds8WYhFI6Tki szVvh9RMDp5ukN4A+9446DDh80FC8fMW32HxgWJfniD3lxSTjFUuZr0hP3ch8hsbeXujuK 3CNv3Bx9QQ+9SEKopzBdU0h4Fq29HoRd4hDOQR3ZEbqjAyYRnjuBA8fwSDf2zA== From: Luca Ceresoli Date: Wed, 04 Feb 2026 09:32:17 +0100 Subject: [PATCH v17 2/3] mtd: Move struct mtd_concat definition to header file Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260204-mtd-virt-concat-v17-2-5e98239bb55b@bootlin.com> References: <20260204-mtd-virt-concat-v17-0-5e98239bb55b@bootlin.com> In-Reply-To: <20260204-mtd-virt-concat-v17-0-5e98239bb55b@bootlin.com> To: Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , Rob Herring , Krzysztof Kozlowski , Conor Dooley , =?utf-8?q?Rafa=C5=82_Mi=C5=82ecki?= Cc: Amit Kumar Mahapatra , Michal Simek , Bernhard Frauendienst , Thomas Petazzoni , linux-mtd@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Ceresoli X-Mailer: b4 0.14.3 X-Last-TLS-Session-Version: TLSv1.3 From: Amit Kumar Mahapatra To enable a more generic approach for concatenating MTD devices, struct mtd_concat should be accessible beyond the mtdconcat driver. Therefore, the definition is being moved to a header file. Signed-off-by: Amit Kumar Mahapatra Signed-off-by: Luca Ceresoli --- drivers/mtd/mtdconcat.c | 12 ------------ include/linux/mtd/concat.h | 12 ++++++++++++ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/drivers/mtd/mtdconcat.c b/drivers/mtd/mtdconcat.c index f56f44aa8625..6f2aaceac669 100644 --- a/drivers/mtd/mtdconcat.c +++ b/drivers/mtd/mtdconcat.c @@ -20,18 +20,6 @@ =20 #include =20 -/* - * Our storage structure: - * Subdev points to an array of pointers to struct mtd_info objects - * which is allocated along with this structure - * - */ -struct mtd_concat { - struct mtd_info mtd; - int num_subdev; - struct mtd_info **subdev; -}; - /* * how to calculate the size required for the above structure, * including the pointer array subdev points to: diff --git a/include/linux/mtd/concat.h b/include/linux/mtd/concat.h index d6f653e07426..b42d9af87c4e 100644 --- a/include/linux/mtd/concat.h +++ b/include/linux/mtd/concat.h @@ -9,6 +9,18 @@ #define MTD_CONCAT_H =20 =20 +/* + * Our storage structure: + * Subdev points to an array of pointers to struct mtd_info objects + * which is allocated along with this structure + * + */ +struct mtd_concat { + struct mtd_info mtd; + int num_subdev; + struct mtd_info **subdev; +}; + struct mtd_info *mtd_concat_create( struct mtd_info *subdev[], /* subdevices to concatenate */ int num_devs, /* number of subdevices */ --=20 2.52.0