James Kilts wrote:
> The patches are now broken into different parts and attached as files to
> avoid the line breaking. While I was at it I added a patch that allows one
> to specify promiscuous mode from the command line while running as master or
> slave (this was quite valuable for me).
I'm fine with that script add-on, I would just call it "capturing mode"
("-c") as it does more that just enabling promisc in the RT-NICs.
Moreover:
> diff -U 3 -HbdprN -- rtnet-0.9.11_original/stack/rtcfg/rtcfg_event.c rtnet-0.9.11/stack/rtcfg/rtcfg_event.c
> --- rtnet-0.9.11_original/stack/rtcfg/rtcfg_event.c 2009-11-12 11:36:56.000000000 +0100
> +++ rtnet-0.9.11/stack/rtcfg/rtcfg_event.c 2009-12-11 16:45:07.000000000 +0100
> @@ -506,6 +507,7 @@ static int rtcfg_server_recv_announce(in
> struct list_head *entry;
> struct rtcfg_frm_announce *announce;
> struct rtcfg_connection *conn;
> + u32 announce_addr;
>
>
> if (rtskb->len < sizeof(struct rtcfg_frm_announce)) {
> @@ -516,6 +518,8 @@ static int rtcfg_server_recv_announce(in
>
> announce = (struct rtcfg_frm_announce *)rtskb->data;
>
> + memcpy(&announce_addr, announce->addr, 4);
> +
This line...
> list_for_each(entry, &rtcfg_dev->spec.srv.conn_list) {
> conn = list_entry(entry, struct rtcfg_connection, entry);
>
> @@ -523,7 +527,7 @@ static int rtcfg_server_recv_announce(in
> #ifdef CONFIG_RTNET_RTIPV4
> case RTCFG_ADDR_IP:
...actually belongs here (because here we know that there is a 4-byte IP
address at announce->addr).
> if (((conn->addr_type & RTCFG_ADDR_MASK) == RTCFG_ADDR_IP) &&
> - (*(u32 *)announce->addr == conn->addr.ip_addr)) {
> + (announce_addr == conn->addr.ip_addr)) {
> /* save MAC address - Ethernet-specific! */
> memcpy(conn->mac_addr, rtskb->mac.ethernet->h_source,
> ETH_ALEN);
Final wish: Please find proper titles for all patches and (unless they
are trivial) a few lines as commit message. Then don't forget your
Signed-off-by, and I will happily merge them.
Thanks!
Jan
PS: Consider using git to ease your patch management.
|