Subject: Re: generic TODR changes for shark and ofppc
To: =?ISO-8859-1?Q?Jorge_Acereda_Maci=E1?= <jacereda@gmail.com>
From: Garrett D'Amore <garrett_damore@tadpole.com>
List: port-arm
Date: 09/12/2006 15:17:41
Jorge Acereda Maciá wrote:
> Garrett D'Amore wrote:
>
>>> Attached, find a diff that significantly changes the real-time-clock
>>> support for shark and ofppc.
>
> Now that I look at it, the ofrtc_match() in -current has a bug:
>
>     if ((l = OF_getprop(oba->oba_phandle, "device_type", type,
>         sizeof type - 1)) < 0 ||
>         l >= sizeof type)
>         return 0;
>
>     return !strcmp(type, "rtc");
>
> That should be strncmp(type, "rtc", 3)

Ah, okay.   I'll fix it, then.  But is it true that there will never be
a type "rtcXXX" for some other string?

-- 
Garrett D'Amore, Principal Software Engineer
Tadpole Computer / Computing Technologies Division,
General Dynamics C4 Systems
http://www.tadpolecomputer.com/
Phone: 951 325-2134  Fax: 951 325-2191