diff options
author | Patrick McHardy <kaber@trash.net> | 2008-01-23 23:34:48 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:11:20 -0500 |
commit | 24beeab539c6f42c4a93e2ff7c3b5f272e60da45 (patch) | |
tree | eb1be7e7d8b3f0f3375bf0d12fd26851e518d9ca /net/sched/sch_atm.c | |
parent | 57e1c487a4f5754cb77abeb00adb21faa88c484f (diff) |
[NET_SCHED]: Use typeful attribute construction helpers
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/sch_atm.c')
-rw-r--r-- | net/sched/sch_atm.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/net/sched/sch_atm.c b/net/sched/sch_atm.c index 19c00074ba1f..4d876598d7df 100644 --- a/net/sched/sch_atm.c +++ b/net/sched/sch_atm.c | |||
@@ -629,14 +629,12 @@ static int atm_tc_dump_class(struct Qdisc *sch, unsigned long cl, | |||
629 | pvc.sap_addr.vci = flow->vcc->vci; | 629 | pvc.sap_addr.vci = flow->vcc->vci; |
630 | NLA_PUT(skb, TCA_ATM_ADDR, sizeof(pvc), &pvc); | 630 | NLA_PUT(skb, TCA_ATM_ADDR, sizeof(pvc), &pvc); |
631 | state = ATM_VF2VS(flow->vcc->flags); | 631 | state = ATM_VF2VS(flow->vcc->flags); |
632 | NLA_PUT(skb, TCA_ATM_STATE, sizeof(state), &state); | 632 | NLA_PUT_U32(skb, TCA_ATM_STATE, state); |
633 | } | 633 | } |
634 | if (flow->excess) | 634 | if (flow->excess) |
635 | NLA_PUT(skb, TCA_ATM_EXCESS, sizeof(u32), &flow->classid); | 635 | NLA_PUT_U32(skb, TCA_ATM_EXCESS, flow->classid); |
636 | else { | 636 | else { |
637 | static u32 zero; | 637 | NLA_PUT_U32(skb, TCA_ATM_EXCESS, 0); |
638 | |||
639 | NLA_PUT(skb, TCA_ATM_EXCESS, sizeof(zero), &zero); | ||
640 | } | 638 | } |
641 | 639 | ||
642 | nla_nest_end(skb, nest); | 640 | nla_nest_end(skb, nest); |