On Wed, Jul 01, 2009 at 04:45:07PM -0700, Warren Turkal wrote: > I don't really care about that. I just want to be able to look at and > decode the values more easily. > > Speaking of pie in the sky, it would also be nice if I could tell it > to spit out a string of binary bits instead of hex sometimes. It would > be even better if I could only spit out certain bits as binary or hex. > > For example, let's say I want something like bits 23 through 29 of the > quad word @ 0x40. > # setpci binary(40.Q[32:23]) > 0x40[29:23]: 0011 0101 10 > > Or let's say I wanted the same thing in hex: > # setpci hex(40.Q[32:23]) > 0x40[29:23]: 0xD6 I've often found Linux to be pretty weak at that kind of thing. I normally have to resort to invoking 'bc' and messing around with obase and ibase. It seems like the kind of thing that hexdump should be able to do, although mybe making it a separate utility would be more useful. Something like the way 'units' works, perhaps. I do think it would be nice to have a separate tool rather than enhancing each tool to be able to do this kind of thing. -- Matthew Wilcox Intel Open Source Technology Centre "Bill, look, we understand that you're interested in selling us this operating system, but compare it to ours. We can't possibly take such a retrograde step." -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html