linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* flushing cache after block io
@ 2007-05-01 13:58 Bahadir Balban
  2007-05-01 17:46 ` Mark Lord
  0 siblings, 1 reply; 5+ messages in thread
From: Bahadir Balban @ 2007-05-01 13:58 UTC (permalink / raw)
  To: linux-ide

Hi,

On an ARM core with write-allocate writeback cache, there can be cache
inconsistencies when an executable file is read from a block device
into memory.

On a compact flash block device driver, I got around this problem by
flushing the caches for the pages that bio buffers use on every bio
read. E.g.

cflash_read_sectors(dev, sect_begin, nsect, buf);
flush_icache_range(buf, buf + nsect*512);

Now I have the same problem with a ATA harddisk connected with a
PDC20269 controller. The question is where would be the best
high-level place to put these flushes so that it works regardless of
what block IO driver is used?


Thanks,
Bahadir

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-05-03 13:30 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-01 13:58 flushing cache after block io Bahadir Balban
2007-05-01 17:46 ` Mark Lord
2007-05-03 13:23   ` Russell King
2007-05-03 13:25   ` Bahadir Balban
2007-05-03 13:30     ` Russell King

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).