Lines Matching defs:nc

49 	struct ncsi_channel *nc, *tmp;
60 ncsi_find_package_and_channel(ndp, h->common.channel, NULL, &nc);
61 if (!nc)
67 spin_lock_irqsave(&nc->lock, flags);
68 ncm = &nc->modes[NCSI_MODE_LINK];
78 nc->id, data & 0x1 ? "up" : "down");
80 chained = !list_empty(&nc->link);
81 state = nc->state;
82 spin_unlock_irqrestore(&nc->lock, flags);
87 nc->id);
92 if (!ndp->multi_package && !nc->package->multi_channel) {
95 ncsi_stop_channel_monitor(nc);
97 list_add_tail_rcu(&nc->link, &ndp->channel_queue);
106 ncm = &nc->modes[NCSI_MODE_TX_ENABLE];
107 if (ncsi_channel_is_last(ndp, nc)) {
112 ncsi_update_tx_channel(ndp, nc->package, nc, NULL);
114 } else if (has_link && nc->package->preferred_channel == nc) {
116 ncsi_update_tx_channel(ndp, nc->package, NULL, nc);
126 ncsi_update_tx_channel(ndp, nc->package,
127 tmp, nc);
143 struct ncsi_channel *nc;
147 ncsi_find_package_and_channel(ndp, h->common.channel, NULL, &nc);
148 if (!nc)
151 spin_lock_irqsave(&nc->lock, flags);
152 if (!list_empty(&nc->link) ||
153 nc->state != NCSI_CHANNEL_ACTIVE) {
154 spin_unlock_irqrestore(&nc->lock, flags);
157 spin_unlock_irqrestore(&nc->lock, flags);
159 ncsi_stop_channel_monitor(nc);
160 spin_lock_irqsave(&nc->lock, flags);
161 nc->state = NCSI_CHANNEL_INVISIBLE;
162 spin_unlock_irqrestore(&nc->lock, flags);
165 nc->state = NCSI_CHANNEL_INACTIVE;
166 list_add_tail_rcu(&nc->link, &ndp->channel_queue);
168 nc->modes[NCSI_MODE_TX_ENABLE].enable = 0;
176 struct ncsi_channel *nc;
182 ncsi_find_package_and_channel(ndp, h->common.channel, NULL, &nc);
183 if (!nc)
186 spin_lock_irqsave(&nc->lock, flags);
187 ncm = &nc->modes[NCSI_MODE_LINK];
190 spin_unlock_irqrestore(&nc->lock, flags);
193 ncm->data[3] & 0x1 ? "" : "not ", nc->id);