[Barrelfish-users] Problems with driver after moving from Mackerel 1 to Mackerel 2 interface.
Timothy Roscoe
troscoe at inf.ethz.ch
Sat Mar 9 11:17:48 CET 2013
Dear Mateusz,
It's hard to say much without looking at your code, but a common
mistake is with the functions which 'insert' field values into data
types: they do not operate 'in place', but instead return a new
value. Think of it as being 'functional' in style, rather than
imperative.
It's very possible you're using these functions to modify descriptors,
and they didn't exist in Mackerel 1 (which used C bitfields for this).
See, for example, the page_select() function in rtl8029.c for an
example.
This is a mistake I've made quite often, and I'm the one who wrote
that bit of the compiler, which suggests that it's not the best piece
of API design :-). However, it's not clear what a "clean" solution
would look like within the constraints of C syntax (and everyone on
the team had strong feelings about not opening the C++ can of
worms...).
Hope this helps.
-- Mothy
At Fri, 8 Mar 2013 23:31:02 +0100, Mateusz Olczak <mateusz at olczak.se> wrote:
> Hello,
>
> I'm trying to move the in-development i825xx network driver from Mackerel 1 to the Mackerel 2 interface but experience problems with the driver after the move.
> Is there any thing particular to take into account when moving to the new Mackerel interface?
>
> The problem experienced is following:
> First I set up a LAN bridge and test it with the i825xx driver which uses the old Mackerel 1 interface. Pinging the host works fine.
> Then I reboot the machine and use the new Mackerel 2 driver. The card gets an IP from internal Qemu/Simics DHCP server.
> However, when I ping the Barrelfish host all returning packets seems to get dropped as I can not see any outgoing traffic at all over the bridge.
>
> I went through both drivers comparing them line by line, the only difference between the drivers is that I use the getters and setters from the Mackerel 2 interface.
>
> Does any one got any hints what could be the cause of this?
>
> Kind Regards,
> // Mateusz
>
>
> _______________________________________________
> Barrelfish-users mailing list
> Barrelfish-users at lists.inf.ethz.ch
> https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users
>
>
>
More information about the Barrelfish-users
mailing list