[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#449292: followup



On Monday 07 January 2008, Joey Hess wrote:
> No, it does not make sense to try to modprobe rtc-dev and only make the
> symlink if the modprobe succeeds. rtc-dev is built into the kernel on
> the nslu2 and some other hardware.

It still seems to me that just modprobing them both by default and printing 
errors to the syslog in case of failure (even when RTC support may already 
be built in) is going to result in unnecessary confusion in the future, for 
example from people who notice a "not loaded" message and flag that as an 
issue in installation reports.

Maybe something like this?

# Try to load RTC module unless there already is RTC support
maybe_load() {
	if [ ! -e /dev/rtc ] && [ ! -e /dev/rtc0 ]; then
		log-output -t hw-detect modprobe -q $1 || return 1
		update-dev
	fi
	return 0
}

if ! (maybe_load rtc || maybe_load rtc-dev); then
	logger -t hw-detect Warning: no RTC support available
fi

Attachment: signature.asc
Description: This is a digitally signed message part.


Reply to: