Hi,
I'm seeking for an advice , related to code cleanness ...
My problem : i'm trying to support 2 "almost" compatible video boards.
the compatible part is ok, the "almost" one is a little bit annoying.
All the registers are the same, with some exeptions:
-increased bitfield size (R [4:0] is now R[6:0] for instance)
-strange things : I have a value, previously stored in one bitfield R1 [7:4]
which is now dispatched in 3 bitfields :
{ R1[24], R1[7:4], R2[30] } R2 being a "new" register added to the
architecture.
(the value was representing a number of 64 pixel wide tiles and to maintain
compatibility, it now reprents the number of .. 32 pixels wide tiles ...)
I think I'm ok with the first type of 'improvment', but i don't really know
how to
cope cleanly with the 2nd type ...
any experiences / ideas / advices ?
Thank you
ghoz
|