5 #define pr_fmt(fmt) KBUILD_MODNAME ":%s: " fmt, __func__
7 #include <linux/errno.h>
8 #include <linux/kernel.h>
10 #include <linux/wait.h>
11 #include <linux/sched.h>
12 #include <linux/atm.h>
15 #include <linux/atmdev.h>
16 #include <linux/bitops.h>
17 #include <linux/slab.h>
40 pr_debug(
"atmsvc: waiting for signaling daemon...\n");
47 pr_debug(
"atmsvc: no signaling daemon\n");
52 atm_force_charge(sigd, skb->
truesize);
54 sk_atm(sigd)->sk_data_ready(sk_atm(sigd), skb->
len);
65 if (!vcc->
dev->ops->change_qos)
69 msg->
reply = vcc->
dev->ops->change_qos(vcc, &msg->
qos,
100 if (!*vcc->
local.sas_addr.prv && !*vcc->
local.sas_addr.pub) {
108 if (session_vcc->
vpi || session_vcc->
vci)
110 session_vcc->
itf = msg->
pvc.sap_addr.itf;
111 session_vcc->
vpi = msg->
pvc.sap_addr.vpi;
112 session_vcc->
vci = msg->
pvc.sap_addr.vci;
113 if (session_vcc->
vpi || session_vcc->
vci)
114 session_vcc->
qos = msg->
qos;
127 if (sk_acceptq_is_full(sk)) {
130 goto as_indicate_complete;
134 pr_debug(
"waking sk_sleep(sk) 0x%p\n", sk_sleep(sk));
136 as_indicate_complete:
144 modify_qos(vcc, msg);
169 static unsigned int session = 0;
171 pr_debug(
"%d (0x%p)\n", (
int)type, vcc);
175 memset(msg, 0,
sizeof(*msg));
208 static void purge_vcc(
struct atm_vcc *vcc)
218 static void sigd_close(
struct atm_vcc *vcc)
227 pr_err(
"closing with requests pending\n");
248 static struct atm_dev sigd_dev = {
249 .ops = &sigd_dev_ops,
261 vcc->
dev = &sigd_dev;
265 #ifdef WAIT_FOR_DEMON