Bug 8342 - sctp_getsockopt_local_addrs_old() calls copy_to_user() while a spinlock is held
Summary: sctp_getsockopt_local_addrs_old() calls copy_to_user() while a spinlock is held
Status: CLOSED CODE_FIX
Alias: None
Product: Networking
Classification: Unclassified
Component: Other (show other bugs)
Hardware: i386 Linux
: P2 normal
Assignee: Arnaldo Carvalho de Melo
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-04-16 14:34 UTC by Matthias Kaehlcke
Modified: 2007-07-13 20:36 UTC (History)
2 users (show)

See Also:
Kernel Version: 2.6.20
Tree: Mainline
Regression: ---


Attachments

Description Matthias Kaehlcke 2007-04-16 14:34:19 UTC
Problem Description:

sctp_getsockopt_local_addrs_old() in net/sctp/socket.c calls copy_to_user()
while the spinlock addr_lock is held. this should not be done as copy_to_user()
might sleep. the call to sctp_copy_laddrs_to_user() while holding the lock is
also problematic as it calls copy_to_user()
Comment 1 Natalie Protasevich 2007-07-07 16:00:51 UTC
Can you put together a patch?
Have you observed any problems or test cases to illustrate this problem?
Thanks.
Comment 2 Natalie Protasevich 2007-07-12 17:29:42 UTC
It looks like commit aad97f38b71dd2ecd730b3a3dce8264d13fbcd56 implements this and has been submitted by vladislav.yasevich@hp.com.
The bug can be closed.

Note You need to log in before you can comment on or make changes to this bug.