Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'for-linus-20190610' of git://git.kernel.dk/linux-block

Pull block cgroup symlink revert from Jens Axboe:
"I talked to Tejun about this offline, and he's not a huge fan of the
symlink.

So let's revert this for now, and Paolo can do this properly for 5.3
instead"

* tag 'for-linus-20190610' of git://git.kernel.dk/linux-block:
cgroup/bfq: revert bfq.weight symlink change

+6 -36
+2 -4
block/bfq-cgroup.c
··· 1046 1046 struct cftype bfq_blkcg_legacy_files[] = { 1047 1047 { 1048 1048 .name = "bfq.weight", 1049 - .link_name = "weight", 1050 - .flags = CFTYPE_NOT_ON_ROOT | CFTYPE_SYMLINKED, 1049 + .flags = CFTYPE_NOT_ON_ROOT, 1051 1050 .seq_show = bfq_io_show_weight, 1052 1051 .write_u64 = bfq_io_set_weight_legacy, 1053 1052 }, ··· 1166 1167 struct cftype bfq_blkg_files[] = { 1167 1168 { 1168 1169 .name = "bfq.weight", 1169 - .link_name = "weight", 1170 - .flags = CFTYPE_NOT_ON_ROOT | CFTYPE_SYMLINKED, 1170 + .flags = CFTYPE_NOT_ON_ROOT, 1171 1171 .seq_show = bfq_io_show_weight, 1172 1172 .write = bfq_io_set_weight, 1173 1173 },
-3
include/linux/cgroup-defs.h
··· 106 106 CFTYPE_WORLD_WRITABLE = (1 << 4), /* (DON'T USE FOR NEW FILES) S_IWUGO */ 107 107 CFTYPE_DEBUG = (1 << 5), /* create when cgroup_debug */ 108 108 109 - CFTYPE_SYMLINKED = (1 << 6), /* pointed to by symlink too */ 110 - 111 109 /* internal flags, do not use outside cgroup core proper */ 112 110 __CFTYPE_ONLY_ON_DFL = (1 << 16), /* only on default hierarchy */ 113 111 __CFTYPE_NOT_ON_DFL = (1 << 17), /* not on default hierarchy */ ··· 543 545 * end of cftype array. 544 546 */ 545 547 char name[MAX_CFTYPE_NAME]; 546 - char link_name[MAX_CFTYPE_NAME]; 547 548 unsigned long private; 548 549 549 550 /*
+4 -29
kernel/cgroup/cgroup.c
··· 1460 1460 1461 1461 static struct kernfs_syscall_ops cgroup_kf_syscall_ops; 1462 1462 1463 - static char *cgroup_fill_name(struct cgroup *cgrp, const struct cftype *cft, 1464 - char *buf, bool write_link_name) 1463 + static char *cgroup_file_name(struct cgroup *cgrp, const struct cftype *cft, 1464 + char *buf) 1465 1465 { 1466 1466 struct cgroup_subsys *ss = cft->ss; 1467 1467 ··· 1471 1471 1472 1472 snprintf(buf, CGROUP_FILE_NAME_MAX, "%s%s.%s", 1473 1473 dbg, cgroup_on_dfl(cgrp) ? ss->name : ss->legacy_name, 1474 - write_link_name ? cft->link_name : cft->name); 1474 + cft->name); 1475 1475 } else { 1476 - strscpy(buf, write_link_name ? cft->link_name : cft->name, 1477 - CGROUP_FILE_NAME_MAX); 1476 + strscpy(buf, cft->name, CGROUP_FILE_NAME_MAX); 1478 1477 } 1479 1478 return buf; 1480 - } 1481 - 1482 - static char *cgroup_file_name(struct cgroup *cgrp, const struct cftype *cft, 1483 - char *buf) 1484 - { 1485 - return cgroup_fill_name(cgrp, cft, buf, false); 1486 - } 1487 - 1488 - static char *cgroup_link_name(struct cgroup *cgrp, const struct cftype *cft, 1489 - char *buf) 1490 - { 1491 - return cgroup_fill_name(cgrp, cft, buf, true); 1492 1479 } 1493 1480 1494 1481 /** ··· 1636 1649 } 1637 1650 1638 1651 kernfs_remove_by_name(cgrp->kn, cgroup_file_name(cgrp, cft, name)); 1639 - if (cft->flags & CFTYPE_SYMLINKED) 1640 - kernfs_remove_by_name(cgrp->kn, 1641 - cgroup_link_name(cgrp, cft, name)); 1642 1652 } 1643 1653 1644 1654 /** ··· 3821 3837 { 3822 3838 char name[CGROUP_FILE_NAME_MAX]; 3823 3839 struct kernfs_node *kn; 3824 - struct kernfs_node *kn_link; 3825 3840 struct lock_class_key *key = NULL; 3826 3841 int ret; 3827 3842 ··· 3849 3866 spin_lock_irq(&cgroup_file_kn_lock); 3850 3867 cfile->kn = kn; 3851 3868 spin_unlock_irq(&cgroup_file_kn_lock); 3852 - } 3853 - 3854 - if (cft->flags & CFTYPE_SYMLINKED) { 3855 - kn_link = kernfs_create_link(cgrp->kn, 3856 - cgroup_link_name(cgrp, cft, name), 3857 - kn); 3858 - if (IS_ERR(kn_link)) 3859 - return PTR_ERR(kn_link); 3860 3869 } 3861 3870 3862 3871 return 0;