Bug 810579 - builtin CD/DVD drive is ignored on Apple Macintosh Mini PowerPC
builtin CD/DVD drive is ignored on Apple Macintosh Mini PowerPC
Product: Fedora
Classification: Fedora
Component: kernel (Show other bugs)
powerpc Linux
unspecified Severity unspecified
: ---
: ---
Assigned To: Kernel Maintainer List
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2012-04-06 16:36 EDT by John Reiser
Modified: 2012-04-18 20:02 EDT (History)
8 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-04-18 20:02:41 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
/var/log/messages including udev_log="debug" (212.81 KB, text/plain)
2012-04-06 16:36 EDT, John Reiser
no flags Details
find /sys | grep hdb (5.11 KB, text/plain)
2012-04-06 16:37 EDT, John Reiser
no flags Details
lspci (1014 bytes, text/plain)
2012-04-06 16:38 EDT, John Reiser
no flags Details
lspci -n (460 bytes, text/plain)
2012-04-06 16:38 EDT, John Reiser
no flags Details

  None (edit)
Description John Reiser 2012-04-06 16:36:20 EDT
Created attachment 575823 [details]
/var/log/messages including udev_log="debug"

Description of problem: The builtin CD/DVD drive on an Apple Macintosh Mini is not recognized for automounting of media, eject, etc.  Instead /dev/hdb does work manually (mount /dev/hdb /mnt; eject /dev/hdb).  An external drive via USB2.0 does works (and gets /dev/sr0 as its name.)

Version-Release number of selected component (if applicable):

How reproducible: every time

Steps to Reproduce:
1. boot Fedora 17 on Apple Macintosh Mini G4 PowerPC
2. insert CD/DVD with ISO 9660 filesystem
Actual results: no attempt to automount the CD/DVD

Expected results: CD/DVD is automounted

Additional info:
Comment 1 John Reiser 2012-04-06 16:37:53 EDT
Created attachment 575824 [details]
find /sys | grep hdb

Here are all the pathnames in /sys that have 'hdb'.
Comment 2 John Reiser 2012-04-06 16:38:35 EDT
Created attachment 575825 [details]
Comment 3 John Reiser 2012-04-06 16:38:57 EDT
Created attachment 575826 [details]
lspci -n
Comment 4 Kay Sievers 2012-04-07 04:09:22 EDT
Libata drivers need to be used, which create /dev/sr0.

The deprecated IDE drivers are not supported at all in recent userspace or
advanced kernel infrastructure like the media presence polling.

There is no way really, to make them work today, they should not even be compiled.
Comment 5 Josh Boyer 2012-04-09 12:56:38 EDT
There's a long sad history of the powerpc Macs having crappy support in the drivers for ATA stuff.

John, if you rmmod ide_pmac and insmod pata_macio does it bind and create the devices one would expect?
Comment 6 John Reiser 2012-04-09 15:16:26 EDT
There is no module ide_pmac nor ide-pmac (not loaded, nor anywhere in /lib/modules/...), and pata_macio already is loaded.  The complete output of "lsmod" is:
Module                  Size  Used by
ipt_MASQUERADE          2384  1 
nf_conntrack_netbios_ns     1137  0 
nf_conntrack_broadcast     1227  1 nf_conntrack_netbios_ns
ip6table_mangle         1816  1 
ip6t_REJECT             4638  4 
nf_conntrack_ipv6       8560  4 
nf_defrag_ipv6          8882  1 nf_conntrack_ipv6
ip6table_filter         1679  1 
ip6_tables             13923  2 ip6table_filter,ip6table_mangle
iptable_nat             5250  1 
nf_nat                 17898  2 iptable_nat,ipt_MASQUERADE
iptable_mangle          1731  1 
nf_conntrack_ipv4       9022  7 nf_nat,iptable_nat
nf_defrag_ipv4          1493  1 nf_conntrack_ipv4
xt_conntrack            3288  8 
nf_conntrack           73459  8 xt_conntrack,nf_conntrack_ipv4,nf_nat,iptable_nat,nf_conntrack_ipv6,nf_conntrack_broadcast,nf_conntrack_netbios_ns,ipt_MASQUERADE
snd_aoa_codec_toonie     2023  2 
snd_aoa_fabric_layout    10306  0 
snd_aoa                15972  2 snd_aoa_fabric_layout,snd_aoa_codec_toonie
snd_aoa_i2sbus         19836  1 
sungem                 29921  0 
snd_aoa_soundbus        4561  2 snd_aoa_i2sbus,snd_aoa_fabric_layout
i2c_powermac            4276  0 
sungem_phy             12014  1 sungem
snd_pcm                87819  1 snd_aoa_i2sbus
snd_page_alloc          6913  1 snd_pcm
snd_timer              21428  1 snd_pcm
snd                    69787  6 snd_timer,snd_pcm,snd_aoa_i2sbus,snd_aoa,snd_aoa_fabric_layout,snd_aoa_codec_toonie
soundcore               6877  1 snd
pmac_zilog             19181  0 
uinput                  7993  0 
ide_cd_mod             28150  0 
pata_macio             14524  0 
firewire_ohci          34566  0 
firewire_core          58815  1 firewire_ohci
crc_itu_t               1347  1 firewire_core
pmac                   16095  1 
radeon                819427  1 
power_supply           12469  1 radeon
i2c_algo_bit            5835  1 radeon
drm_kms_helper         31114  1 radeon
ttm                    70961  1 radeon
drm                   216810  3 ttm,drm_kms_helper,radeon
i2c_core               27928  5 drm,drm_kms_helper,i2c_algo_bit,radeon,i2c_powermac
Comment 7 Josh Boyer 2012-04-09 15:35:24 EDT
(In reply to comment #6)
> There is no module ide_pmac nor ide-pmac (not loaded, nor anywhere in
> /lib/modules/...), and pata_macio already is loaded.  The complete output of
> "lsmod" is:
> -----
> Module                  Size  Used by
> pmac                   16095  1 

Sorry, my mistake on the name.  This is the one I was talking about.  Blacklist it and try again please.
Comment 8 John Reiser 2012-04-09 16:28:22 EDT
Appending " rdblacklist=pmac" to the kernel boot command line works.  /dev/sr0 and /dev/disk/by-label/<actual-DVD-label> have the right stuff.  Inserting a DVD causes an icon to appear on the Xfce session desktop, and double clicking the icon gets the platter mounted under /run/media/<user>/<actual-DVD-label>. "eject\r" does eject the platter.  The root filesystem is now /dev/sda4 instead of /dev/hda4.  Filesystems on an external USB2.0 disk appear as /dev/sdb* whereas the old names were /dev/sda*.
Comment 9 John Reiser 2012-04-09 16:29:19 EDT
... and module pata_macio now has use count equal to 1.
Comment 10 Josh Boyer 2012-04-09 20:29:04 EDT
Karsten, you had mentioned something similar to this last week.  Does this bug describe the issue you were seeing?
Comment 11 Karsten Hopp 2012-04-10 07:26:45 EDT
Although my problem was early in the installer, this is the same problem. The CD/DVD device uses the old pata (pmac) module when it works just fine with sata.
As udev doesn't have any support for pata devices anymore, userspace will fail.
But as this report shows, even the old Mac Minis work just fine with sata so I think we can get rid of the pac module.
Comment 12 Karsten Hopp 2012-04-10 07:27:26 EDT
s/pac/pmac/, but I think you've already guessed that
Comment 13 Josh Boyer 2012-04-10 09:52:18 EDT
(In reply to comment #12)
> s/pac/pmac/, but I think you've already guessed that

OK.  I'll just turn it off then.  Should be in the next builds.
Comment 14 Josh Boyer 2012-04-10 10:59:34 EDT
Changed in f17/rawhide.  Should be in the next builds of each.
Comment 15 John Reiser 2012-04-11 12:08:32 EDT
ybin and /etc/yaboot.conf do not cooperate with names /dev/sda*.  For example, the old usage was /dev/hda2.  Now /dev/hda2 does not exist, so ybin complains.  ybin won't accept /dev/sda2.  Faking /dev/hda2 -> /dev/sda2 via hardlink or symlink both fail.  I tried adding the line "ofboot=/disk@0:2" to yaboot.conf.  Then ybin accepts it (and "boot=/dev/sda2"_, but actual booting fails (brief "folder with question mark" screen, then menu for linux/macos/openfirmware/cd/net, but typing a letter gets the gray blank screen and CPU hangs.)

I recover with Fedora 12 DVD (boot "linux resuce"), keep a multi-boot setup (Fedora 12, Fedora 15 [for bootstrapping rpm-4.9.1], Fedora 17, MacOSX), and run ybin under Fedora 12.
Comment 16 Karsten Hopp 2012-04-11 12:46:47 EDT
that's not correct. Harddisks already used the sata module in F16 and had /dev/sdX device names. I had /dev/sdX in my f16 yaboot.conf and ybin worked without any problems.
Comment 17 John Reiser 2012-04-11 13:55:16 EDT
That's what I have encountered.  It may be due to problems with how F17 got installed on this box whose last fully-successful install (and running base) was F12, but it _did_ happen.

On my installation of F17, with yaboot-1.3.17-2.fc16.ppc (and "rpm --verify" does not complain), installing a new boot stanza using "ybin" certainly did not work at all the first time, has displayed various problems during attempts to fix it, and booting still does not succeed (except after going back to F12 and running ybin there.)

The first problem was /dev/hda* (as specified in bootstrap from yaboot.conf of F12 when ybin was run under F17, with a stanza that named the correct F17 kernel and initrd) did not exist, so ybin complained and refused to make changes.  After changing yaboot.conf to specify /dev/sda*, then ybin complained that those names were not configured.  After fiddling around trying hardlinks, symlinks, and by adding "ofboot=/disk@0:2" (and later removing that) and a few detours through rescue mode, F12, and F17 (and running ybin under various circumstances) now ybin on F17 does not complain about /dev/sda*.  However, boot does not work.  I see the Apple "no system folder" icon (folder with question mark) briefly, then the text menu for kind of boot (linux/macos/...), but typing a letter results in a hang with full-screen gray.

I will get back to F17, then try yabootconfig in the hope that this will fix stale files in the AppleBootstrap partition.
Comment 18 Josh Boyer 2012-04-18 20:02:41 EDT
This is in 3.3.1-5.

Note You need to log in before you can comment on or make changes to this bug.