From: Rajeev Kumar <rajeev_kumar@mentor.com>
To: Richard Weinberger <richard@nod.at>, <dwmw2@infradead.org>,
<computersforpeace@gmail.com>
Cc: <dedekind1@gmail.com>, <linux-mtd@lists.infradead.org>,
<stable@vger.kernel.org>
Subject: Re: [PATCH 2/2] ubi: attach: do not return -EINVAL if the mtd->numeraseregions is 1
Date: Mon, 25 Jul 2016 16:46:57 +0530 [thread overview]
Message-ID: <5795F529.2060807@mentor.com> (raw)
In-Reply-To: <5795EA8B.2040209@nod.at>
Richard
On 07/25/2016 04:01 PM, Richard Weinberger wrote:
> Rajeev,
>
> Am 25.07.2016 um 11:46 schrieb Rajeev Kumar:
>> If the master mtd does not have any slave mtd partitions,
>> and its numeraseregions is one(only has one erease block), and
>> we attach the master mtd with : ubiattach -m 0 -d 0
>>
>> We will meet the error:
>> -------------------------------------------------------
>> root ~$ ubiattach /dev/ubi_ctrl -m 0 -d 0
>> UBI: attaching mtd0 to ubi0
>> UBI error: io_init: multiple regions, not implemented
>> ubiattach: error!: cannot attach mtd0
>> error 22 (Invalid argument)
>> -------------------------------------------------------
>>
>> In fact, if there is only one "erase block", we should not
>> prevent the attach.
>>
>> This patch is tested against 3.14 kernel and only build test is
>> performed against current upstream master branch.
>
> The more interesting question is, why is ->numeraseregions not 0?
>
> The comment in the header says:
> /* Data for variable erase regions. If numeraseregions is zero,
> * it means that the whole device has erasesize as given above.
> */
>
> So, if your MTD erase regions with the same size, it should be 0.
>
> IIRC we had such a discussion already on linux-mtd and it was not clear
> whether numeraseregions of 0 and 1 are equal or not.
>
Could you please pass the link
Thanks in advance
~Rajeev
> Thanks,
> //richard
>
next prev parent reply other threads:[~2016-07-25 11:17 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-25 9:46 [PATCH 1/2] MTD: UBI: speed up init by moving status messages to debugfs Rajeev Kumar
2016-07-25 9:46 ` [PATCH 2/2] ubi: attach: do not return -EINVAL if the mtd->numeraseregions is 1 Rajeev Kumar
2016-07-25 10:31 ` Richard Weinberger
2016-07-25 11:16 ` Rajeev Kumar [this message]
2016-07-25 11:20 ` Richard Weinberger
2016-07-29 18:24 ` Brian Norris
2016-08-04 6:30 ` Artem Bityutskiy
2016-09-23 11:20 ` Chugh, Sanjeev
2016-09-23 11:37 ` Chugh, Sanjeev
2016-10-26 12:26 ` Chugh, Sanjeev
2016-07-25 10:31 ` [PATCH 1/2] MTD: UBI: speed up init by moving status messages to debugfs Richard Weinberger
2016-07-25 11:23 ` Rajeev Kumar
2016-07-25 11:32 ` Richard Weinberger
2016-07-25 16:47 ` Greg KH
2016-07-25 20:39 ` Richard Weinberger
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=5795F529.2060807@mentor.com \
--to=rajeev_kumar@mentor.com \
--cc=computersforpeace@gmail.com \
--cc=dedekind1@gmail.com \
--cc=dwmw2@infradead.org \
--cc=linux-mtd@lists.infradead.org \
--cc=richard@nod.at \
--cc=stable@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.