* [PATCH] UBI: Fastmap: Fix PEB array type
@ 2015-10-17 17:55 Ezequiel Garcia
2015-10-17 18:04 ` Richard Weinberger
0 siblings, 1 reply; 4+ messages in thread
From: Ezequiel Garcia @ 2015-10-17 17:55 UTC (permalink / raw)
To: linux-mtd; +Cc: Richard Weinberger, hs, Ezequiel Garcia
The PEB array is an array of __be32, so let's fix the
scan_pool() prototype accordingly.
Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
---
drivers/mtd/ubi/fastmap.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mtd/ubi/fastmap.c b/drivers/mtd/ubi/fastmap.c
index db3defdfc3c0..c867707a1d04 100644
--- a/drivers/mtd/ubi/fastmap.c
+++ b/drivers/mtd/ubi/fastmap.c
@@ -383,7 +383,7 @@ static void unmap_peb(struct ubi_attach_info *ai, int pnum)
* < 0 indicates an internal error.
*/
static int scan_pool(struct ubi_device *ubi, struct ubi_attach_info *ai,
- int *pebs, int pool_size, unsigned long long *max_sqnum,
+ __be32 *pebs, int pool_size, unsigned long long *max_sqnum,
struct list_head *eba_orphans, struct list_head *free)
{
struct ubi_vid_hdr *vh;
--
2.5.2
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] UBI: Fastmap: Fix PEB array type
2015-10-17 17:55 [PATCH] UBI: Fastmap: Fix PEB array type Ezequiel Garcia
@ 2015-10-17 18:04 ` Richard Weinberger
2015-10-17 18:10 ` Ezequiel Garcia
0 siblings, 1 reply; 4+ messages in thread
From: Richard Weinberger @ 2015-10-17 18:04 UTC (permalink / raw)
To: Ezequiel Garcia, linux-mtd; +Cc: hs
Am 17.10.2015 um 19:55 schrieb Ezequiel Garcia:
> The PEB array is an array of __be32, so let's fix the
> scan_pool() prototype accordingly.
>
> Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
> ---
> drivers/mtd/ubi/fastmap.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mtd/ubi/fastmap.c b/drivers/mtd/ubi/fastmap.c
> index db3defdfc3c0..c867707a1d04 100644
> --- a/drivers/mtd/ubi/fastmap.c
> +++ b/drivers/mtd/ubi/fastmap.c
> @@ -383,7 +383,7 @@ static void unmap_peb(struct ubi_attach_info *ai, int pnum)
> * < 0 indicates an internal error.
> */
> static int scan_pool(struct ubi_device *ubi, struct ubi_attach_info *ai,
> - int *pebs, int pool_size, unsigned long long *max_sqnum,
> + __be32 *pebs, int pool_size, unsigned long long *max_sqnum,
> struct list_head *eba_orphans, struct list_head *free)
> {
> struct ubi_vid_hdr *vh;
The change makes sense, but does it fix a real issue?
I suspect it silences a compiler warning, which one?
Thanks,
//richard
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] UBI: Fastmap: Fix PEB array type
2015-10-17 18:04 ` Richard Weinberger
@ 2015-10-17 18:10 ` Ezequiel Garcia
2015-11-06 22:18 ` Richard Weinberger
0 siblings, 1 reply; 4+ messages in thread
From: Ezequiel Garcia @ 2015-10-17 18:10 UTC (permalink / raw)
To: Richard Weinberger; +Cc: linux-mtd@lists.infradead.org, hs
On 17 October 2015 at 15:04, Richard Weinberger <richard@nod.at> wrote:
> Am 17.10.2015 um 19:55 schrieb Ezequiel Garcia:
>> The PEB array is an array of __be32, so let's fix the
>> scan_pool() prototype accordingly.
>>
>> Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
>> ---
>> drivers/mtd/ubi/fastmap.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/mtd/ubi/fastmap.c b/drivers/mtd/ubi/fastmap.c
>> index db3defdfc3c0..c867707a1d04 100644
>> --- a/drivers/mtd/ubi/fastmap.c
>> +++ b/drivers/mtd/ubi/fastmap.c
>> @@ -383,7 +383,7 @@ static void unmap_peb(struct ubi_attach_info *ai, int pnum)
>> * < 0 indicates an internal error.
>> */
>> static int scan_pool(struct ubi_device *ubi, struct ubi_attach_info *ai,
>> - int *pebs, int pool_size, unsigned long long *max_sqnum,
>> + __be32 *pebs, int pool_size, unsigned long long *max_sqnum,
>> struct list_head *eba_orphans, struct list_head *free)
>> {
>> struct ubi_vid_hdr *vh;
>
> The change makes sense, but does it fix a real issue?
No, doesn't fix any issue as far as I know.
> I suspect it silences a compiler warning, which one?
>
It fixes a silly warning that's printed if -Wpointer-sign. Linux
disables the warning, so this patch doesn't even fix a warning.
I'd say it's merely cosmetic.
--
Ezequiel García, VanguardiaSur
www.vanguardiasur.com.ar
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] UBI: Fastmap: Fix PEB array type
2015-10-17 18:10 ` Ezequiel Garcia
@ 2015-11-06 22:18 ` Richard Weinberger
0 siblings, 0 replies; 4+ messages in thread
From: Richard Weinberger @ 2015-11-06 22:18 UTC (permalink / raw)
To: Ezequiel Garcia; +Cc: Richard Weinberger, hs, linux-mtd@lists.infradead.org
On Sat, Oct 17, 2015 at 8:10 PM, Ezequiel Garcia
<ezequiel@vanguardiasur.com.ar> wrote:
> On 17 October 2015 at 15:04, Richard Weinberger <richard@nod.at> wrote:
>> Am 17.10.2015 um 19:55 schrieb Ezequiel Garcia:
>>> The PEB array is an array of __be32, so let's fix the
>>> scan_pool() prototype accordingly.
>>>
>>> Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
Applied!
--
Thanks,
//richard
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-11-06 22:18 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-17 17:55 [PATCH] UBI: Fastmap: Fix PEB array type Ezequiel Garcia
2015-10-17 18:04 ` Richard Weinberger
2015-10-17 18:10 ` Ezequiel Garcia
2015-11-06 22:18 ` Richard Weinberger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox