History

ksmbd: use SOCK_NONBLOCK type for kernel_accept()

I found that normally it is O_NONBLOCK but there are different value for some arch. /include/linux/net.h: #ifndef SOCK_NONBLOCK #define SOCK_NONBLOCK O_NONBLOCK #endif /arch/alpha/include/asm/socket.h: #define SOCK_NONBLOCK 0x40000000 Use SOCK_NONBLOCK instead of O_NONBLOCK for kernel_accept().

Namjae Jeon committed 4 years ago

Commit fe0fde01 parent f2906aa1 file · +1 −1Browse files

Unified · Split

fs/ksmbd/transport_tcp.c+1−1
@@ -230,7 +230,7 @@ static int ksmbd_kthread_fn(void *p) · 229 unmodified lines
230230 break;
231231 }
232232 ret = kernel_accept(iface->ksmbd_socket, &client_sk,
233− O_NONBLOCK);
233+ SOCK_NONBLOCK);
234234 mutex_unlock(&iface->sock_release_lock);
235235 if (ret) {
236236 if (ret == -EAGAIN)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t