Skip to content

Commit 0467ca3

Browse files
committed
Merge branch 'slab/for-6.1/trivial' into slab/for-next
Trivial fixes and cleanups: - unneeded variable removals, by ye xingchen
2 parents e45cc28 + 2bfbb02 commit 0467ca3

File tree

2 files changed

+3
-12
lines changed

2 files changed

+3
-12
lines changed

mm/slab_common.c

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -511,13 +511,9 @@ EXPORT_SYMBOL(kmem_cache_destroy);
511511
*/
512512
int kmem_cache_shrink(struct kmem_cache *cachep)
513513
{
514-
int ret;
515-
516-
517514
kasan_cache_shrink(cachep);
518-
ret = __kmem_cache_shrink(cachep);
519515

520-
return ret;
516+
return __kmem_cache_shrink(cachep);
521517
}
522518
EXPORT_SYMBOL(kmem_cache_shrink);
523519

mm/slub.c

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5837,17 +5837,14 @@ static ssize_t slab_attr_show(struct kobject *kobj,
58375837
{
58385838
struct slab_attribute *attribute;
58395839
struct kmem_cache *s;
5840-
int err;
58415840

58425841
attribute = to_slab_attr(attr);
58435842
s = to_slab(kobj);
58445843

58455844
if (!attribute->show)
58465845
return -EIO;
58475846

5848-
err = attribute->show(s, buf);
5849-
5850-
return err;
5847+
return attribute->show(s, buf);
58515848
}
58525849

58535850
static ssize_t slab_attr_store(struct kobject *kobj,
@@ -5856,16 +5853,14 @@ static ssize_t slab_attr_store(struct kobject *kobj,
58565853
{
58575854
struct slab_attribute *attribute;
58585855
struct kmem_cache *s;
5859-
int err;
58605856

58615857
attribute = to_slab_attr(attr);
58625858
s = to_slab(kobj);
58635859

58645860
if (!attribute->store)
58655861
return -EIO;
58665862

5867-
err = attribute->store(s, buf, len);
5868-
return err;
5863+
return attribute->store(s, buf, len);
58695864
}
58705865

58715866
static void kmem_cache_release(struct kobject *k)

0 commit comments

Comments
 (0)