The attached enables a getty on hvc0 when installing under Xen. I'm not terribly happy with doing this by checking for the presence of both /sys/bus/xen && /dev/hvc0. Would modifying the way $console is determined at lines 32-37 to work off of /proc/cmdline in the same way grub-installer works (i.e. pulling out the last console=) be acceptable? I'm unsure of the impact this will have on other architectures. In particular ppc using hvc0 -- would hvc0 then be detected twice? i.e. Once via console= and once via /proc/device-tree. It looks to me as if this wouldn't matter in practise since the second time it removes any previously existing co: line. I've also attached a trivial patch to hw-detect. Since the Xen kernels now feature module autoloading I'm not sure there is any circumstance where it would actually be used but it seems like a reasonable thing to do for completeness. Cheers, Ian. -- Ian Campbell I know what "custody" [of the children] means. "Get even." That's all custody means. Get even with your old lady. -- Lenny Bruce
Index: finish-install/finish-install.d/90console =================================================================== --- finish-install/finish-install.d/90console (revision 53286) +++ finish-install/finish-install.d/90console (working copy) @@ -95,7 +95,13 @@ *) exit 0 ;; esac +elif [ -e "/sys/bus/xen" ] && [ -e "/dev/hvc0" ]; then + console="hvc0" +else + console="" +fi +if [ "$console" ] ; then log "Setting up virtualized serial console on /dev/$console" if [ -f /target/etc/inittab ]; then # Disable regular VTs
Index: hw-detect/devnames-static.txt =================================================================== --- hw-detect/devnames-static.txt (revision 53286) +++ hw-detect/devnames-static.txt (working copy) @@ -133,6 +133,7 @@ wavelan_cs:Lucent WaveLAN/IEEE + compatibles 802.11 wd:ISA WD 8003/8013 or SMC Elite/16 Ethernet winbond-840:Winbond W89c840 Ethernet +xen-netfront:Xen Virtual Ethernet xirc2ps_cs:Xircom PCMCIA Ethernet xircom_cb:Xircom Cardbus Ethernet xircom_tulip_cb:Xircom CBE-100 Ethernet
Attachment:
signature.asc
Description: This is a digitally signed message part