lkml.org 
[lkml]   [1999]   [Nov]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: move block #A to block #B on a given device.
Thanks for your replies, guys. I will follow your advices.
Moreover, in my case, I need to write a function that atomically moves a
contiguous range of blocks from one range to another (on the same device).

If you think it may be used by anything outside my need (BFS is a
contiguous filesystem so to extend a file beyond the currently allocated
last block it *may* have to move it to a gap) then I can put it in
fs/buffer.c and export it instead of making static to my module.

But for now I will make it static to my module.

Regards,
------
Tigran A. Aivazian | http://www.sco.com
Escalations Research Group | tel: +44-(0)1923-813796
Santa Cruz Operation Ltd | http://www.ocston.org/~tigran

On Thu, 4 Nov 1999, Mikulas Patocka wrote:

> > Tigran Aivazian <tigran@sco.COM> writes:
> >
> > > or should the getblk() above be replaced with bread(dev, B, 512)?
> >
> > No.
> >
> > > don't want to read block B as its data is going to be discarded anyway,
> > > why generate extra io?
> >
> > Exactly.
>
> I think doing pure getblk is wrong (someone else can call bread and
> overwrite data in buffer). There should be bh = getblk();
> mark_buffer_uptodate(bh, 1)
>
> Mikulas Patocka
>
>


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.031 / U:0.252 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site