• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/linux/linux-2.6/drivers/net/

Lines Matching refs:pf

90 #define PF_TO_X(pf, X)		container_of(pf, X, file)
92 #define PF_TO_PPP(pf) PF_TO_X(pf, struct ppp)
93 #define PF_TO_CHANNEL(pf) PF_TO_X(pf, struct channel)
243 static int ppp_unattached_ioctl(struct ppp_file *pf, struct file *file,
268 static void init_ppp_file(struct ppp_file *pf, int kind);
558 struct ppp_file *pf = file->private_data;
561 if (pf != 0) {
563 if (pf->kind == INTERFACE) {
564 ppp = PF_TO_PPP(pf);
568 if (atomic_dec_and_test(&pf->refcnt)) {
569 switch (pf->kind) {
571 ppp_destroy_interface(PF_TO_PPP(pf));
574 ppp_destroy_channel(PF_TO_CHANNEL(pf));
585 struct ppp_file *pf = file->private_data;
592 if (pf == 0)
594 add_wait_queue(&pf->rwait, &wait);
597 skb = skb_dequeue(&pf->rq);
601 if (pf->dead)
603 if (pf->kind == INTERFACE) {
609 struct ppp *ppp = PF_TO_PPP(pf);
623 remove_wait_queue(&pf->rwait, &wait);
645 struct ppp_file *pf = file->private_data;
649 if (pf == 0)
652 skb = alloc_skb(count + pf->hdrlen, GFP_KERNEL);
655 skb_reserve(skb, pf->hdrlen);
662 skb_queue_tail(&pf->xq, skb);
664 switch (pf->kind) {
666 ppp_xmit_process(PF_TO_PPP(pf));
669 ppp_channel_push(PF_TO_CHANNEL(pf));
682 struct ppp_file *pf = file->private_data;
685 if (pf == 0)
687 poll_wait(file, &pf->rwait, wait);
689 if (skb_peek(&pf->rq) != 0)
691 if (pf->dead)
693 else if (pf->kind == INTERFACE) {
695 struct ppp *ppp = PF_TO_PPP(pf);
743 struct ppp_file *pf = file->private_data;
753 if (pf == 0)
754 return ppp_unattached_ioctl(pf, file, cmd, arg);
769 if (pf->kind == INTERFACE) {
770 ppp = PF_TO_PPP(pf);
783 if (pf->kind == CHANNEL) {
784 struct channel *pch = PF_TO_CHANNEL(pf);
809 if (pf->kind != INTERFACE) {
815 ppp = PF_TO_PPP(pf);
975 static int ppp_unattached_ioctl(struct ppp_file *pf, struct file *file,
2744 init_ppp_file(struct ppp_file *pf, int kind)
2746 pf->kind = kind;
2747 skb_queue_head_init(&pf->xq);
2748 skb_queue_head_init(&pf->rq);
2749 atomic_set(&pf->refcnt, 1);
2750 init_waitqueue_head(&pf->rwait);