stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michael Schmitz <schmitzmic@gmail.com>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: linux-block@vger.kernel.org, axboe@kernel.dk,
	linux-m68k@vger.kernel.org, hch@lst.de, martin@lichtvoll.de,
	fthain@linux-m68k.org, stable@vger.kernel.org
Subject: Re: [PATCH v12 2/3] block: change annotation of rdb_CylBlocks in affs_hardblocks.h
Date: Sun, 18 Jun 2023 15:10:38 +1200	[thread overview]
Message-ID: <e29dcf24-367f-4304-9b01-7913e0dcf650@gmail.com> (raw)
In-Reply-To: <CAMuHMdXo+Za3_Bz-PaLhq_oZzEzkN=g5YyDp=vaX7485WuE=Cg@mail.gmail.com>

Hi Geert,

Am 17.06.2023 um 23:08 schrieb Geert Uytterhoeven:
> On Sat, Jun 17, 2023 at 12:36 AM Michael Schmitz <schmitzmic@gmail.com> wrote:
>> The Amiga partition parser module uses signed int for partition sector
>> address and count, which will overflow for disks larger than 1 TB.
>>
>> Use u64 as type for sector address and size to allow using disks up to
>> 2 TB without LBD support, and disks larger than 2 TB with LBD. The RBD
>> format allows to specify disk sizes up to 2^128 bytes (though native
>> OS limitations reduce this somewhat, to max 2^68 bytes), so check for
>> u64 overflow carefully to protect against overflowing sector_t.
>>
>> This bug was reported originally in 2012, and the fix was created by
>> the RDB author, Joanne Dow <jdow@earthlink.net>. A patch had been
>> discussed and reviewed on linux-m68k at that time but never officially
>> submitted (now resubmitted as patch 1 of this series).
>>
>> Patch 3 (this series) adds additional error checking and warning
>> messages. One of the error checks now makes use of the previously
>> unused rdb_CylBlocks field, which causes a 'sparse' warning
>> (cast to restricted __be32).
>>
>> Annotate all 32 bit fields in affs_hardblocks.h as __be32, as the
>> on-disk format of RDB and partition blocks is always big endian.
>>
>> Reported-by: Martin Steigerwald <Martin@lichtvoll.de>
>> Closes: https://bugzilla.kernel.org/show_bug.cgi?id=43511
>> Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
>> Message-ID: <201206192146.09327.Martin@lichtvoll.de>
>> Cc: <stable@vger.kernel.org> # 5.2
>> Signed-off-by: Michael Schmitz <schmitzmic@gmail.com>
>> Reviewed-by: Christoph Hellwig <hch@lst.de>
>
> Reviewed-by: Geert Uytterhoeven <geert@linux-m68k.org>

Thanks - now I notice the patch title for this one doesn't fit too well 
anymore.

Would a change of title mess up the common patch tracking tools?

Cheers,

	Michael

>
> Gr{oetje,eeting}s,
>
>                         Geert
>

  reply	other threads:[~2023-06-18  3:10 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20230616223616.6002-1-schmitzmic@gmail.com>
2023-06-16 22:36 ` [PATCH v12 1/3] block: fix signed int overflow in Amiga partition support Michael Schmitz
2023-06-16 22:36 ` [PATCH v12 2/3] block: change annotation of rdb_CylBlocks in affs_hardblocks.h Michael Schmitz
2023-06-17 11:08   ` Geert Uytterhoeven
2023-06-18  3:10     ` Michael Schmitz [this message]
2023-06-18  7:51       ` Geert Uytterhoeven
2023-06-19  2:53         ` Michael Schmitz
2023-06-16 22:36 ` [PATCH v12 3/3] block: add overflow checks for Amiga partition support Michael Schmitz

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=e29dcf24-367f-4304-9b01-7913e0dcf650@gmail.com \
    --to=schmitzmic@gmail.com \
    --cc=axboe@kernel.dk \
    --cc=fthain@linux-m68k.org \
    --cc=geert@linux-m68k.org \
    --cc=hch@lst.de \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-m68k@vger.kernel.org \
    --cc=martin@lichtvoll.de \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).