Date: Fri, 29 Aug 2008 13:21:25 +0100 From: Dieter <freebsd@sopwith.solgatos.com> To: Sean Bruno <sbruno@miralink.com> Cc: freebsd-firewire@freebsd.org Subject: Re: This is where I'm going with fwcontrol Message-ID: <200808292021.UAA25442@sopwith.solgatos.com> In-Reply-To: Your message of "Fri, 29 Aug 2008 11:16:28 PDT." <48B83CFC.6030906@miralink.com>
next in thread | previous in thread | raw e-mail | index | archive | help
> > Should > > > > > >> Message ID Root ID R T Gap Count > >> 00(2 bits) (5 bits) 1 1 (6 bits) > >> > > > > be > > > > Message ID Root ID R T Gap Count > > 00(2 bits) (6 bits) 1 1 (6 bits) > > > > send_phy_config() ANDs root_node with 0x3f, and the > > "Physical ID" field in the controller register is > > 6 bits. > > > Well, according to the 1394 documentation, no. The root ID is > definitely 5 bits. > > The gap count is also 5 bits, I must have mis-counted. So, really it > should be: > > Message ID Root ID R T Gap Count > 00(2 bits) (5 bits) 1 1 (5 bits) Looking at "Table 5. PHY Register Map" in the VIA controller datasheet (page 24 of the pdf) http://www.datasheetarchive.com/pdf-datasheets/Datasheets-6/DSA-113181.pdf the "Physical ID" field is 6 bits, as is the "Gap Count" field. I don't have the IEEE documentation, so I'll have to assume you are correct about it saying 5 bits. So why doesn't the controller datasheet agree with the IEEE doc? Granted one is a controller register and the other is a packet, but I'd expect these individual fields to be the same size. > This means that the Root ID and the Gap Count cannot exceed 0x3f(63). That's 6 bits. 5 bits would be 0x1f = 31 decimal. > So, the masking > of the values instead of generating and error seems wrong to me. I'm > going to put in error checking > to make sure the values comply with the specification and document the > correct values in the man page > and the comments of the code. Sounds good.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200808292021.UAA25442>