1710 }
1711#ifdef CONFIG_ISDN_PPP
1712 if (minor <= ISDN_MINOR_PPPMAX)
1713 return (isdn_ppp_ioctl(minor - ISDN_MINOR_PPP, file, cmd, arg));
1714#endif
1715 return -ENODEV;
1716
1717#undef name
1718#undef bname
1719#undef iocts
1720#undef phone
1721#undef cfg
1722}
1723
1724
1725
1726
1727static int
1728isdn_open(struct inode *ino, struct file *filep)
1729{
1730 uint minor = iminor(ino);
1731 int drvidx;
1732 int chidx;
1733 int retval = -ENODEV;
1734
1735 lock_kernel();
1736 if (minor == ISDN_MINOR_STATUS) {
1737 infostruct *p;
1738
1739 if ((p = kmalloc(sizeof(infostruct), GFP_KERNEL))) {
1740 p->next = (char *) dev->infochain;
1741 p->private = (char *) &(filep->private_data);
1742 dev->infochain = p;
1743
1744 filep->private_data = (char *) 1;
1745 retval = 0;
1746 goto out;
1747 } else {
1748 retval = -ENOMEM;
1749 goto out;
1750 }