public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: R.E.Wolff@BitWizard.nl (Rogier Wolff)
To: Andries.Brouwer@cwi.nl
Cc: jari.ruusu@pp.inet.fi, torvalds@transmeta.com,
	R.E.Wolff@BitWizard.nl, axboe@suse.de,
	linux-kernel@vger.kernel.org
Subject: Re: loop device broken in 2.4.6-pre5
Date: Tue, 26 Jun 2001 12:52:29 +0200 (MEST)	[thread overview]
Message-ID: <200106261052.MAA16148@cave.bitwizard.nl> (raw)
In-Reply-To: <UTC200106261041.MAA454888.aeb@vlet.cwi.nl> from "Andries.Brouwer@cwi.nl" at "Jun 26, 2001 12:41:51 pm"

Andries.Brouwer@cwi.nl wrote:
>     From jari.ruusu@pp.inet.fi Tue Jun 26 10:20:51 2001
> 
>     This patch fixes the problem. Please consider applying.
> 
>     --- linux-2.4.6-pre5/drivers/block/loop.c    Sat Jun 23 07:52:39 2001
>     +++ linux/drivers/block/loop.c    Tue Jun 26 09:21:47 2001
>     @@ -653,7 +653,7 @@
>          bs = 0;
>          if (blksize_size[MAJOR(lo_device)])
>              bs = blksize_size[MAJOR(lo_device)][MINOR(lo_device)];
>     -    if (!bs)
>     +    if (!bs || S_ISREG(inode->i_mode))
>              bs = BLOCK_SIZE;
>      
>          set_blocksize(dev, bs);
> 
> But why 1024? Next week your neighbour comes and has a file-backed
> loop device with an odd number of 512-byte sectors.
> If you want a guarantee, then I suppose one should pick 512.
> (Or make the set blocksize ioctl also work on loop devices.)

I thought the change was a "quick hack" that would make stuff work
(page cache?) near the end of the file. That would mean that this kind
of "quick hack" won't work. 

But if it does anyway, then indeed 512 would be a more appropriate
choice.

I thought I had to convince people, so I chose a sitation that I hoped
people would understand to be likely/possible, to prevent reactions:
"No filesystem will use the last odd numbered 512bytes of a
partition".

				Roger. 

-- 
** R.E.Wolff@BitWizard.nl ** http://www.BitWizard.nl/ ** +31-15-2137555 **
*-- BitWizard writes Linux device drivers for any device you may have! --*
* There are old pilots, and there are bold pilots. 
* There are also old, bald pilots. 

  reply	other threads:[~2001-06-26 10:52 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-06-26 10:41 loop device broken in 2.4.6-pre5 Andries.Brouwer
2001-06-26 10:52 ` Rogier Wolff [this message]
2001-06-26 17:59 ` Jari Ruusu
2001-06-26 19:14 ` Anton Altaparmakov
2001-06-27 11:54   ` Jari Ruusu
  -- strict thread matches above, loose matches on Subject: below --
2001-06-26 13:31 Andries.Brouwer
2001-06-21 22:58 Andries.Brouwer
2001-06-22 13:59 ` Jari Ruusu
2001-06-26  8:18   ` Jari Ruusu
2001-06-25 16:31 ` Rogier Wolff
2001-06-21 16:43 Jari Ruusu

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=200106261052.MAA16148@cave.bitwizard.nl \
    --to=r.e.wolff@bitwizard.nl \
    --cc=Andries.Brouwer@cwi.nl \
    --cc=axboe@suse.de \
    --cc=jari.ruusu@pp.inet.fi \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@transmeta.com \
    /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