Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 Sep 2005 11:09:06 +0530
From:      rashmi ns <nsrashmi@gmail.com>
To:        bugi@lists.redbrick.dcu.ie, freebsd-hackers@freebsd.org
Subject:   KINDLY HELP : error while kldloading a pci,character driver
Message-ID:  <9f99931605092022396c685991@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hi All,

This is the output of dmesg i get when i kldload my module=20
***************************************************************************=
**********************************
<DALLAS HDLC CONTROLLER > mem 0x40300000-0x40300fff irq 11 at device
11.0 on pci1
WARNING: Device driver "hdlc_cdev" has wrong version and is disabled.=20
Recompile KLD module.
***************************************************************************=
**********************************
In attach function of pci driver i'll try to create character device
interface  i just register this like this
 sc->hdlc_cdev =3D make_dev (&hdlc_cdevsw,0, UID_ROOT,
                                GID_WHEEL, 0600, "hdlc_cdev");

where=20
static struct cdevsw  hdlc_cdevsw =3D {

        .d_name     =3D "hdlc_cdev",
        .d_maj      =3D CDEV_MAJOR,   /*251*/
        .d_open     =3D hdlc_open,
        .d_read     =3D hdlc_read,
};
in read and write functions i just have some printf statements inorder to t=
est .
when i do=20
ls -l /dev/hdlc_cdev
crw-------  1 root  wheel  251,   0 Sep 20 19:38 /dev/hdlc_cdev
cat /dev/hdlc_cdev=20
cat: /dev/hdlc_cdev: Device not configured

but why do i get this error

Thanks in Advance ,
Rashmi.N.S



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9f99931605092022396c685991>