Re: Fix zero length sys_cacheflush

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>>>>> On Wed, 19 Oct 2005 14:29:02 +0100, Ralf Baechle <ralf@xxxxxxxxxxxxxx> said:

>> I found cacheflush(0, 0, 0) will crash the system.
>> 
>> This is because flush_icache_range(start, end) tries to flushing
>> whole address space (0 - ffffffff) if both start and end are zero
>> (at least in c-r4k.c).

ralf> Applied,

Thanks.

BTW, sparse complains for this "unsigned long __user addr".

asmlinkage int sys_cacheflush(unsigned long __user addr,
	unsigned long bytes, unsigned int cache)

/work/git/linux-mips/arch/mips/mm/cache.c:59:7: warning: dereference of noderef expression

I suppose the "unsigned long __user addr" means that the "addr"
variable itself is an userspace object.  So its usage is wrong, isn't
it?

---
Atsushi Nemoto


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux