Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 84010 - pktsetup does not work due to incorrect path to control device
Summary: pktsetup does not work due to incorrect path to control device
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Daniel Drake (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-03 14:59 UTC by Eugeny
Modified: 2010-01-11 01:26 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch that fixes path to control device. Must be applied after http://w1.894.telia.com/~u89404340/patches/packet/udftools-1.0.0b3.patch.bz2 (pktsetup.linux-2.6.10.udev.devpath.diff,540 bytes, patch)
2005-03-03 15:01 UTC, Eugeny
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eugeny 2005-03-03 14:59:45 UTC
Incorrect path to packet writing control device in file pktsetup/pktsetup.c causes ioctl errors.

Reproducible: Always
Steps to Reproduce:
1. using linux-2.6.10
2. compile pktcdvd kernel module, modprobe it
3. emerge sys-fs/udftools
4. run ``pktsetup pktcdvd0 /dev/cdrw_device''

Actual Results:  
ctl open: Not a directory

Expected Results:  
block device /dev/pktcdvd0 should appear

Portage 2.0.51-r15 (default-linux/x86/2004.3, gcc-3.3.5,
glibc-2.3.4.20040808-r1, 2.6.10 i686)
=================================================================
System uname: 2.6.10 i686 Intel(R) Pentium(R) 4 CPU 2.40GHz
Gentoo Base System version 1.4.16
Python:              dev-lang/python-2.3.4-r1 [2.3.4 (#1, Feb 16 2005, 23:48:16)]
dev-lang/python:     2.3.4-r1
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.7.9-r1, 1.8.5-r3, 1.5, 1.4_p6, 1.6.3, 1.9.4
sys-devel/binutils:  2.15.92.0.2-r1
sys-devel/libtool:   1.5.10-r4
virtual/os-headers:  2.4.22, 2.4.21-r1
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-O3 -march=pentium3 -mcpu=pentium3 -msse -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.2/share/config
/usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown
/usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O3 -march=pentium3 -mcpu=pentium3 -msse -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms"
GENTOO_MIRRORS="http://trumpetti.atm.tut.fi/gentoo"
LANG="en_US"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/tmp/portage"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X alsa apm arts avi berkdb bitmap-fonts cdr crypt cups curl directfb
dvd emacs emboss encode esd f77 fam flac font-server foomaticdb fortran gdbm gif
gpm gtk gtk2 guile imagemagick imlib ipv6 jack java jpeg ldap libg++ libwww mad
mikmod mmx motif mpeg mysql ncurses oggvorbis opengl oss pam pdflib perl png
python quicktime readline ruby samba sdl slang speex spell sse ssl svga tcltk
tcpd tiff truetype truetype-fonts type1-fonts xml xml2 xmms xv zlib"
Unset:  ASFLAGS, CBUILD, CTARGET, LC_ALL, LDFLAGS, PORTDIR_OVERLAY
Comment 1 Eugeny 2005-03-03 15:01:28 UTC
Created attachment 52581 [details, diff]
Patch that fixes path to control device. Must be applied after http://w1.894.telia.com/~u89404340/patches/packet/udftools-1.0.0b3.patch.bz2

Changing path from /dev/pktcdvd/control to /dev/pktcdvd makes it work.
Comment 2 Daniel Drake (RETIRED) gentoo-dev 2005-06-02 14:58:06 UTC
Fixed in udev-058 (possibly earlier releases too). You just need to use some
udev rules like:

# packet devices
KERNEL="pktcdvd", NAME="pktcdvd/control", GROUP="cdrw", MODE="0660"
KERNEL="pktcdvd[0-9]*", NAME="pktcdvd/pktcdvd%n", GROUP="cdrw", MODE="0660"
Comment 3 David W Noon 2010-01-11 01:26:31 UTC
This problem has reappeared quite recently, with the message:
  Can't find pktcdvd character device
turning up when attempting to set up the CD-RW drive for UDF. In particular, there is a patch named udftools-1.0.0b3.patch[.bz2] that contains the following code at line 135:

+               if (strcmp(name, "pktcdvd") == 0) {

If this were changed so that the C code became

   if (strcmp(name, "pktcdvd/control") == 0 || strcmp(name, "pktcdvd") == 0) {

or

               if (strncmp(name, "pktcdvd", 7) == 0) {

then it should pick up the character device whether using the newer or older naming convention. So, who wants to patch the patch?