Subject: Re: port-arm/34684 (OMAP patch 5/5: OSK5912 board support)
To: None <gnats-bugs@NetBSD.org>
From: Bucky Katz <bucky@picovex.com>
List: netbsd-bugs
Date: 01/05/2007 20:38:40
--=-=-=
christos@zoulas.com (Christos Zoulas) writes:
> The following reply was made to PR port-arm/34684; it has been noted by GNATS.
>
> From: christos@zoulas.com (Christos Zoulas)
> To: gnats-bugs@NetBSD.org, gnats-admin@netbsd.org,
> netbsd-bugs@netbsd.org, Bucky Katz <bucky@picovex.com>
> Cc:
> Subject: Re: port-arm/34684 (OMAP patch 5/5: OSK5912 board support)
> Date: Fri, 5 Jan 2007 23:13:01 -0500
>
> On Jan 6, 3:55am, bucky@picovex.com (Bucky Katz) wrote:
> -- Subject: Re: port-arm/34684 (OMAP patch 5/5: OSK5912 board support)
>
> | It's not part of that patch and it needs to be applied because it
> | contains the board support for the OSK591 machdep as well as the conf
> | files for that board.
>
> Bucky, can you please cvs update and send me an updated patch? I tried
> to apply patch 5 and it seems to have reversed another patch you send us.
>
> chridtos
>
Here, finally, is the last patch needed to bring the cvs tree into agreement with what we've sent you, adding generic TOD clock to arm
--=-=-=
Content-Type: application/octet-stream
Content-Disposition: attachment; filename=patch.rtc
Content-Transfer-Encoding: base64
Content-Description: generic tod support for arm
c3JjL3N5cy9hcmNoL2FybS9lcDkzeHgvZXBjbGsuYwotLS0gLi4vY3ZzL3NyYy9zeXMvYXJjaC9h
cm0vZXA5M3h4L2VwY2xrLmMJMjAwNi0wOS0xMCAyMDowMjoxOC4wMDAwMDAwMDAgLTA3MDAKKysr
IHNyYy9zeXMvYXJjaC9hcm0vZXA5M3h4L2VwY2xrLmMJMjAwNy0wMS0wNSAxODo0Njo1OC4wMDAw
MDAwMDAgLTA4MDAKQEAgLTMyNCw5MyArMzI0LDMgQEAKIAkJdGlja3MgPSBUSU1FUjRWQUwoKTsK
IAl9CiB9Ci0KLSNpZm5kZWYgX19IQVZFX0dFTkVSSUNfVE9EUgotCi10b2RyX2NoaXBfaGF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