2.5: further llseek cleanup (3/3)
PATCH 1/1 2.5: further llseek cleanup (3/3)
Hi Robert,
I think the pcilynx change is wrong:
Review
Quoted 4 lines
(quoted diff) +2
-2- if (newoffs < 0 || newoffs > PCILYNX_MAX_MEMORY + 1) return -EINVAL; + if (newoffs < 0 || newoffs > PCILYNX_MAX_MEMORY + 1) { + lock_kernel();
^^^^^^ unlock_kernel()?
Review
Quoted 4 lines
(quoted diff) +2
-0+ return -EINVAL; + } file->f_pos = newoffs;
^^^^^^^^^^^^^^^^^^^ where is the unlock here?
Quoted 1 line
return newoffs;
--
Manfred
Quoted 3 lines · Manfred Spraul
Hi Robert,
I think the pcilynx change is wrong:
Indeed. Thank you, Manfred.
Linus, patch against 2.5.5-pre1 is attached. Please, apply.
Robert Love
drivers/ieee1394/pcilynx.c +2 -1
@@ -748,10 +748,11 @@ }if (newoffs <0 || newoffs >PCILYNX_MAX_MEMORY +1 ) { -lock_kernel (); +unlock_kernel ();return -EINVAL ; } +unlock_kernel (); file->f_pos = newoffs;return newoffs; }
Quoted 3 lines · Robert Love
Indeed. Thank you, Manfred.
Linus, patch against 2.5.5-pre1 is attached. Please, apply.
Ugh, another one. Linus, please apply.
Robert Love
arch/cris/drivers/eeprom.c +3 -3
@@ -470,17 +470,17 @@/* truncate position */ if (file->f_pos <0 ) { - file->f_pos =0 ; -unlock_kernel (); + file->f_pos =0 ; ret = -EOVERFLOW ; } - +if (file->f_pos >= eeprom.size) { file->f_pos = eeprom.size -1 ; ret = -EOVERFLOW ; } +unlock_kernel ();return ( ret ); }