Antoni Segura Puimedon has posted comments on this change. Change subject: ipwrapper: switch link polling to netlink ......................................................................
Patch Set 9: (4 comments) Thanks for the review Francesco http://gerrit.ovirt.org/#/c/23248/9/lib/vdsm/netlink.py File lib/vdsm/netlink.py: Line 65: )} > OK, this can be just personal taste so feel free to ignore: Done Line 70: _nl_addr2str > If I'm not mistaken, this returns a c_char_p with the name, if so can be us Done Line 92: master = _rtnl_link_get_master(link) Line 93: if master >= 1: Line 94: master_name = (c_char * CHARBUFFSIZE)() Line 95: data['master'] = _rtnl_link_i2name(cache, master, master_name, Line 96: sizeof(master_name)) > idea, feel free to ignore. Worth moving this and line 85 above in a common That's funny, what you propose is exactly how I did it in the patch I sent to python-ethtool. Line 97: Line 98: state = _rtnl_link_get_operstate(link) Line 99: operstate = (c_char * CHARBUFFSIZE)() Line 100: _rtnl_link_operstate2str(state, operstate, sizeof(operstate)) Line 97: Line 98: state = _rtnl_link_get_operstate(link) Line 99: operstate = (c_char * CHARBUFFSIZE)() Line 100: _rtnl_link_operstate2str(state, operstate, sizeof(operstate)) Line 101: data['state'] = operstate.value > same as line 70 above Done Line 102: return data Line 103: Line 104: Line 105: def getLinks(): -- To view, visit http://gerrit.ovirt.org/23248 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I09a120155e3c5be15c237171620e5c996c2af681 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Antoni Segura Puimedon <[email protected]> Gerrit-Reviewer: Antoni Segura Puimedon <[email protected]> Gerrit-Reviewer: Assaf Muller <[email protected]> Gerrit-Reviewer: Dan Kenigsberg <[email protected]> Gerrit-Reviewer: Francesco Romani <[email protected]> Gerrit-Reviewer: Nir Soffer <[email protected]> Gerrit-Reviewer: Ondřej Svoboda <[email protected]> Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
