On Mon, Feb 17, 2014 at 09:52:16PM +0200, Or Gerlitz wrote: > On Mon, Feb 17, 2014, Dan Carpenter <dan.carpen...@oracle.com> wrote: > > Hello Moni Shoua, > > This is a semi-automatic email about new static checker warnings. > > > > The patch ad4885d279b6: "IB/mlx4: Build the port IBoE GID table > > properly under bonding" from Feb 5, 2014, leads to the following > Smatch complaint: > > Hi Dan, > > I'd like to act such that our patches go through your 0-day testing of > static checkers before submissions. For that end, do I just need to > set up publicly accessible git tree anywhere I like and let you know, > or it needs to be on kernel.org? >
So, this wasn't a 0-day thing, right? I am not sure why 0-day missed it. Perhaps the cross function database didn't have enough information. You'd have to ask Fengguang about 0-day. I know all the the git trees in linux-next are a part of 0-day and all the branches get tested. Presumably you would set up a separate branch for 0-day pre-testing. Btw, I was so proud of this warning. It is very complicated for a static checker to know that curr_netdev is non-NULL on line 1743. regards, dan carpenter > thanks, > > Or. > > > > > drivers/infiniband/hw/mlx4/main.c:1749 mlx4_ib_scan_netdevs() > > error: we previously assumed 'curr_netdev' could be null (see line > > 1722) > > > > drivers/infiniband/hw/mlx4/main.c > > 1721 > > 1722 if (curr_netdev) { > > ^^^^^^^^^^^ > > Check. > > > > 1723 port_state = (netif_running(curr_netdev) && > > netif_carrier_ok(curr_netdev)) ? > > 1724 IB_PORT_ACTIVE : > > IB_PORT_DOWN; > > 1725 mlx4_ib_set_default_gid(ibdev, curr_netdev, > > port); > > 1726 } else { > > 1727 reset_gid_table(ibdev, port); > > 1728 } > > 1729 /* if using bonding/team and a slave port is down, > > we don't the bond IP > > 1730 * based gids in the table since flows that select > > port by gid may get > > 1731 * the down port. > > 1732 */ > > 1733 if (curr_master && (port_state == IB_PORT_DOWN)) { > > 1734 reset_gid_table(ibdev, port); > > 1735 mlx4_ib_set_default_gid(ibdev, curr_netdev, > > port); > > 1736 } > > 1737 /* if bonding is used it is possible that we add it > > to masters > > 1738 * only after IP address is assigned to the net > > bonding > > 1739 * interface. > > 1740 */ > > 1741 if (curr_master && (old_master != curr_master)) { > > 1742 reset_gid_table(ibdev, port); > > 1743 mlx4_ib_set_default_gid(ibdev, curr_netdev, > > port); > > 1744 mlx4_ib_get_dev_addr(curr_master, ibdev, > > port); > > 1745 } > > 1746 > > 1747 if (!curr_master && (old_master != curr_master)) { > > 1748 reset_gid_table(ibdev, port); > > 1749 mlx4_ib_set_default_gid(ibdev, curr_netdev, > > port); > > ^^^^^^^^^^^ > > Dereferenced without checking. > > > > 1750 mlx4_ib_get_dev_addr(curr_netdev, ibdev, > > port); > > 1751 } > > > > regards, > > dan carpenter > > -- > > To unsubscribe from this list: send the line "unsubscribe linux-rdma" in > > the body of a message to majord...@vger.kernel.org > > More majordomo info at http://vger.kernel.org/majordomo-info.html _______________________________________________ kbuild mailing list kbuild@lists.01.org https://lists.01.org/mailman/listinfo/kbuild