]> Pileus Git - ~andy/linux/blobdiff - net/core/netprio_cgroup.c
Linux 3.14
[~andy/linux] / net / core / netprio_cgroup.c
index 9b7cf6c85f82447d3e03f33cd2c599de13ed3644..9043caedcd083bf48836d0a970d48d8c533f86ee 100644 (file)
@@ -30,7 +30,7 @@
 #define PRIOMAP_MIN_SZ         128
 
 /*
- * Extend @dev->priomap so that it's large enough to accomodate
+ * Extend @dev->priomap so that it's large enough to accommodate
  * @target_idx.  @dev->priomap.priomap_len > @target_idx after successful
  * return.  Must be called under rtnl lock.
  */
@@ -173,14 +173,14 @@ static u64 read_prioidx(struct cgroup_subsys_state *css, struct cftype *cft)
        return css->cgroup->id;
 }
 
-static int read_priomap(struct cgroup_subsys_state *css, struct cftype *cft,
-                       struct cgroup_map_cb *cb)
+static int read_priomap(struct seq_file *sf, void *v)
 {
        struct net_device *dev;
 
        rcu_read_lock();
        for_each_netdev_rcu(&init_net, dev)
-               cb->fill(cb, dev->name, netprio_prio(css, dev));
+               seq_printf(sf, "%s %u\n", dev->name,
+                          netprio_prio(seq_css(sf), dev));
        rcu_read_unlock();
        return 0;
 }
@@ -238,7 +238,7 @@ static struct cftype ss_files[] = {
        },
        {
                .name = "ifpriomap",
-               .read_map = read_priomap,
+               .seq_show = read_priomap,
                .write_string = write_priomap,
        },
        { }     /* terminate */