From: Marco Felsch <m.felsch@pengutronix.de>
To: barebox@lists.infradead.org
Subject: [PATCH v2 2/3] mci: mci-core: set the DEVFS_IS_MCI_MAIN_PART_DEV flag
Date: Thu, 6 May 2021 18:26:15 +0200 [thread overview]
Message-ID: <20210506162616.11593-2-m.felsch@pengutronix.de> (raw)
In-Reply-To: <20210506162616.11593-1-m.felsch@pengutronix.de>
Set the new introduced flag to be able to check if the cdev is an
mmc/mci device.
Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
---
v2:
- only set the flag for MMC_BLK_DATA_AREA_MAIN
drivers/mci/mci-core.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/mci/mci-core.c b/drivers/mci/mci-core.c
index 017f25d35f..a160b98894 100644
--- a/drivers/mci/mci-core.c
+++ b/drivers/mci/mci-core.c
@@ -426,8 +426,10 @@ static void mci_part_add(struct mci *mci, uint64_t size,
part->part_cfg = part_cfg;
part->idx = idx;
- if (area_type == MMC_BLK_DATA_AREA_MAIN)
+ if (area_type == MMC_BLK_DATA_AREA_MAIN) {
part->blk.cdev.device_node = mci->host->hw_dev->device_node;
+ part->blk.cdev.flags |= DEVFS_IS_MCI_MAIN_PART_DEV;
+ }
mci->nr_parts++;
}
--
2.29.2
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2021-05-06 16:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-06 16:26 [PATCH v2 1/3] driver: add flag to check if cdev is an mci device Marco Felsch
2021-05-06 16:26 ` Marco Felsch [this message]
2021-05-06 16:26 ` [PATCH v2 3/3] fs: add linux_rootarg 'root=mmcblkXpN' support Marco Felsch
2021-05-09 13:32 ` Roland Hieber
2021-05-10 10:26 ` Marco Felsch
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210506162616.11593-2-m.felsch@pengutronix.de \
--to=m.felsch@pengutronix.de \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox