The helper str_no_yes is introduced to reback "no/yes"
string literal. We can use str_no_yes() helper instead
of open coding the same.

Signed-off-by: Hongbo Li <lihongb...@huawei.com>
---
 net/core/sock.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/core/sock.c b/net/core/sock.c
index 542bc5462cb5..f976bb4a402f 100644
--- a/net/core/sock.c
+++ b/net/core/sock.c
@@ -4086,7 +4086,7 @@ static void proto_seq_printf(struct seq_file *seq, struct 
proto *proto)
                   sock_prot_memory_allocated(proto),
                   sock_prot_memory_pressure(proto),
                   proto->max_header,
-                  proto->slab == NULL ? "no" : "yes",
+                  str_no_yes(proto->slab == NULL),
                   module_name(proto->owner),
                   proto_method_implemented(proto->close),
                   proto_method_implemented(proto->connect),
-- 
2.34.1


Reply via email to