Re: RFC: cleaning up j720ssp.c

Quentin Garnier <[email protected]>
Newsgroups gmane.os.netbsd.ports.hpcarm
Message-ID <[email protected]>
On Mon, Feb 27, 2006 at 01:03:11AM +0100, Peter Postma wrote:
> On Mon, Feb 27, 2006 at 12:39:11AM +0100, Quentin Garnier wrote:
> > On Sun, Feb 26, 2006 at 11:28:21PM +0100, Peter Postma wrote:
> > > On Thu, Feb 23, 2006 at 01:49:52AM +0100, Quentin Garnier wrote:
> > > 
> > > I had to make a small change to hpcapm.c, removing the include
> > > machine/autoconf.h. I don't think that will affect the other hpc ports
> > > but I'll cross-compile them to be sure.
> > 
> > I think it's a left over;  it probably was needed for struct
> > mainbus_attach_args, which of course is not used anymore.
> > 
> > > And there's a minor compatibility problem... the apmdev device uses
> > > a different major number from the apm device, so users will need to
> > > create a new device node. I've created a new major file
> > 
> > Hum, no.  Just use the same major as before.
> > 
> 
> Uh, ok.
> 
> > > (hpcarm/conf/majors.hpcarm) for this (arm/conf/majors.arm32 didn't feel
> > > right). A new apm binary is also required to query the status.
> > 
> > I'd rather have a MI definition for hpcapm.  But we'll still need a
> > definition for compat_30 anyway.
> > 
> 
> Ok, but then I don't see how you want to keep compatibility, we still
> need to change the no. for the MI definition.

You can have several numbers for one device.  The compatibility one will
only be compiled in under compat_30, MAKEDEV will be changed to create
the new node, etc.

You can work with only files.hpcarm using number 103 right now, it's
just fine.  I just think that sharing hpcapm major between the relevant
arches would be better.
 
> > Why would a new binary be required?  AFAICT, the ABI doesn't change.
> > 
> 
> There's a small difference in the APM_IOC_GETPOWER ioctl: the old apm
> uses "_IOR" and the new uses "_IOWR".

Oh, right.  We just have to add support for OAPM_IOC_GETPOWER in
hpc/apm/apmdev.c, and we're good.  It's a one-liner.

> > > So maybe this should be noted in src/UPDATING and/or -current-users.
> > 
> > I don't think we have a compatibility problem.  I'll have to think more
> > about it though.
> > 
> 
> There might only be a ABI compatibility problem, but we'll have to live
> with that...

Nah, this is easy compatibility stuff :)

-- 
Quentin Garnier - [email protected] - [email protected]
"When I find the controls, I'll go where I like, I'll know where I want
to be, but maybe for now I'll stay right here on a silent sea."
KT Tunstall, Silent Sea, Eye to the Telescope, 2004.
signature.asc (application/pgp-signature, 478 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (NetBSD)

iQEVAwUBRAJHkdgoQloHrPnoAQKB3Af/RuyNd3hjBkFucoKqp/HYFNJ9lCY+ug3+
pWTDnl9kqntdJbFsjvLpEELj9PTlyJa4FdBRh/p7PFHXKu2y8hiTm3rdhFPrgR4R
0POAj2TgkXr1C9w6T4yQWVY3A4wyTNvu7i1gcDOK2A8Rdj6JLE6foUxfqNuw0NCS
9GvjPkqm74t1i/doMiyFKv5gmcDtqYkl5dmNVZbl0q/g+7qLms3tMlaHJSLeBJRc
6/iEp/Xuuai/ocTmjCkrrsPXS+972QGF5uYSrWViA8c4h6/sudLs0HPfQwxTbwU1
2Jz9nCXURzLhnb1a7USPBWVBuhoMZU0cenIORC+dqyNKEl9uyzmuxg==
=3MAI
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.