First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 163233
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Project Gentopia <gentopia@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Jerzy Borkowski <jubork@ncac.torun.pl>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
halfloppy.patch patch against hal-0.5.7.1 source patch Jerzy Borkowski 2007-01-22 14:42 0000 581 bytes Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 163233 depends on: Show dependency tree
Show dependency graph
Bug 163233 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)







View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2007-01-22 12:10 0000
after "modprobe floppy", the floppy device does not
show up as a device in nautilus/computer. I've traced down
the problem to (hald/linux2/hotplug.c:285) :

                is_partition = (isdigit(hotplug_event->sysfs.sysfs_path[len -
1])
                                && ! strstr(hotplug_event->sysfs.sysfs_path,
"/block/sr")) ||
                               strstr (hotplug_event->sysfs.sysfs_path,
"/fakevolume") ;

which should read :
                is_partition = (isdigit(hotplug_event->sysfs.sysfs_path[len -
1])
                                && (! strstr(hotplug_event->sysfs.sysfs_path,
"/block/fd"))
                                && ! strstr(hotplug_event->sysfs.sysfs_path,
"/block/sr")) ||
                               strstr (hotplug_event->sysfs.sysfs_path,
"/fakevolume") ;

Without the above fix, the code treats the floppy as a partition,
since its name (/sys/block/fd0) ends with a digit.

On related note, attempt to mount a floppy fails (hal with the above fix)
unless hal scripts are modified to define filesystem type during
floppy mount operation. As it is now, hal calls :

mount -o rw,uid=.... /dev/floppy/0 /media/floppy

which fails (vfat is not in /etc/partitions), however the following works :

mount -o rw,uid=.... -t vfat,auto /dev/floppy/0 /media/floppy


Reproducible: Always

Steps to Reproduce:
1.remove floppy from /etc/fstab
2.log into gnome session
3.rmmod floppy + modprobe floppy

Actual Results:  
no floppy icon in nautilus/computer
no floppy icon in drivemount gnome-panel applet

Expected Results:  
floppy icon shows up in nautilus/computer
floppy icon shows up in drivemount gnome-panel applet

2.6.19-gentoo-r1/gcc-4.1.1/libc-2.5
x86 && amd64

------- Comment #1 From Doug Goldstein 2007-01-22 14:12:50 0000 -------
Patches should not be inline in comments... it makes them difficult to parse
out. Attach the patch as a file.

I've never heard of "/etc/partitions", however there is a "/proc/filesystems"
and if vfat is not in there, then it's an issue with your configuration. HAL
should not hardcode floppy partition types to vfat. auto, which is what the
above call does is proper. auto is based on your "/proc/filesystems", which
again leads to a mis-configuration.

Telling me kernel, gcc, and glibc is no substitute for emerge --info. Attach
it.

------- Comment #2 From Jerzy Borkowski 2007-01-22 14:42:05 0000 -------
Created an attachment (id=107794) [edit]
patch against hal-0.5.7.1 source

Note: sys-apps/hal/files/hal-0.5.7.1-sr-driver.patch
must be applied before this patch,
otherwise patch will likely fail

------- Comment #3 From Jerzy Borkowski 2007-01-22 15:18:15 0000 -------
(In reply to comment #1)
> Attach the patch as a file.

I've submitted the patch.

> I've never heard of "/etc/partitions", however there is a "/proc/filesystems"
> and if vfat is not in there, then it's an issue with your configuration. HAL
> should not hardcode floppy partition types to vfat. auto, which is what the
> above call does is proper. auto is based on your "/proc/filesystems", which
> again leads to a mis-configuration.

yup, I meant /etc/filesystems (and not /etc/partitions), sorry for
misinformation, and thanks for correcting me. 
I managed to resolve the "mount -t auto ...." part of problem.
It was wrong configuration in /etc/filesystems (one needs to 
specify both vfat _and_ msdos in there, otherwise some very 
old floppies can not be mounted).

> Telling me kernel, gcc, and glibc is no substitute for emerge --info. Attach
> it.

Gentoo Base System version 1.12.6
Portage 2.1.1-r2 (default-linux/x86/2006.1, gcc-4.1.1/vanilla, glibc-2.5-r0,
2.6.19-gentoo-r1 i686)
=================================================================
System uname: 2.6.19-gentoo-r1 i686 Intel(R) Pentium(R) 4 CPU 2.80GHz
Last Sync: Sat, 02 Dec 2006 12:00:03 +0000
ccache version 2.3 [enabled]
app-admin/eselect-compiler: 2.0.0_rc2-r1
dev-java/java-config: 1.3.7, 2.0.30
dev-lang/python:     2.4.4
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.3
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.9.6-r2
sys-devel/binutils:  2.17
sys-devel/gcc-config: [Not Present]
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r1
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=pentium4 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/NX/etc /usr/NX/home /usr/kde/3.5/env
/usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb
/usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/eselect/compiler
/etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo
/etc/texmf/web2c"
CXXFLAGS="-O2 -march=pentium4 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig buildpkg ccache distlocks metadata-transfer parallel-fetch
sandbox sfperms strict"
GENTOO_MIRRORS="http://ftp.belnet.be/mirror/rsync.gentoo.org/gentoo/
http://ftp.easynet.nl/mirror/gentoo/
http://sunsite.cnlab-switch.ch/ftp/mirror/gentoo/
http://ftp.uni-erlangen.de/pub/mirrors/gentoo http://gentoo.inode.at/"
LANG="pl_PL.UTF-8"
LINGUAS="en ar au bg br ca ch cn cz de dk fi fr ee es gr he hr hu il in is it
ja ko lt lu lv ma my no pl pt ro ru se sl sk sr sv tr ua uk za"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress
--force --whole-file --delete --delete-after --stats --timeout=180
--exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/camk/portage-overlay/camk
/usr/camk/portage-overlay/zugaina"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X a52 aac acl acpi alsa arts audiofile berkdb bitmap-fonts bluetooth
bonobo cairo cddb cdparanoia cdr cjk cli cracklib crypt css cups curl dbus divx
djvu dlloader dri dv dvd dvdr dvdread effects elibc_glibc encode esd exif f77
fam ffmpeg flac font-server fortran ftp gcj gd gdbm gif gmedia gmp gnome gnutls
gphoto2 gpm graphviz gstreamer gtk gtkhtml hal howl iconv idn ieee1394
imagemagick imap input_devices_evdev input_devices_keyboard input_devices_mouse
ipod ipv6 isdnlog jabber java jpeg jpeg2k junit kde kernel_linux lcms ldap
libg++ libgda libnotify linguas_ar linguas_au linguas_bg linguas_br linguas_ca
linguas_ch linguas_cn linguas_cz linguas_de linguas_dk linguas_ee linguas_en
linguas_es linguas_fi linguas_fr linguas_gr linguas_he linguas_hr linguas_hu
linguas_il linguas_in linguas_is linguas_it linguas_ja linguas_ko linguas_lt
linguas_lu linguas_lv linguas_ma linguas_my linguas_no linguas_pl linguas_pt
linguas_ro linguas_ru linguas_se linguas_sk linguas_sl linguas_sr linguas_sv
linguas_tr linguas_ua linguas_uk linguas_za live livecd lm_sensors
logitech-mouse mad
mbox milter mmx mng mp3 mysql nas ncurses network nls nntp nomalloccheck nptl
nptlonly nsplugin objc odbc ogg oggvorbis opengl pam pcre pdf perl php pic png
pop ppds pppd python qt3 quicktime readline real realmedia reflection rtc samba
sasl scanner session slang slp smartcard spl sse sse2 ssl svg tcltk tcpd tetex
theora tiff truetype truetype-fonts type1-fonts udev unicode usb userland_GNU
v4l v4l2 video_cards_apm video_cards_ark video_cards_ati video_cards_chips
video_cards_cirrus video_cards_cyrix video_cards_dummy video_cards_fbdev
video_cards_fglrx video_cards_glint video_cards_i128 video_cards_i740
video_cards_i810 video_cards_imstt video_cards_mga video_cards_neomagic
video_cards_nsc video_cards_nv video_cards_nvidia video_cards_radeon
video_cards_rendition video_cards_s3 video_cards_s3virge video_cards_savage
video_cards_siliconmotion video_cards_sis video_cards_sisusb video_cards_tdfx
video_cards_tga video_cards_trident video_cards_tseng video_cards_v4l
video_cards_vesa video_cards_vga video_cards_via video_cards_vmware
video_cards_voodoo vorbis wifi win32codecs wma
wmf wmp xfs xine xml xml2 xorg xprint xv xvid zlib"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LDFLAGS,
PORTAGE_RSYNC_EXTRA_OPTS

------- Comment #4 From Doug Goldstein 2007-01-30 16:38:57 0000 -------
Fixed in hal-0.5.7.1-r4

First Last Prev Next    No search results available      Search page      Enter new bug