Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp5306542ybe; Tue, 17 Sep 2019 06:09:17 -0700 (PDT) X-Google-Smtp-Source: APXvYqw9alO+RePm6BU4a0GKI9FoWXTfFoQgzdrI1ikaC44nvGLxSSHPdPkYSl/nN5vQ+3Uh3zzO X-Received: by 2002:a50:e691:: with SMTP id z17mr4538915edm.84.1568725757130; Tue, 17 Sep 2019 06:09:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568725757; cv=none; d=google.com; s=arc-20160816; b=cRxfAJH4zV+1Sha6ORijRMmOxx3zN9A+ODW60q0SjhhtLM8NmUZbwBfHl13HQzbaOo BL28D5tmF7SNXHbLp6Vk46erEX5X6DAXSaOhOiUp593/elkWk0UmotglsHQTT0m/HKar sx1WBkWF0pcCXocEd7GL3U6siDOC6c6hi9mWn/JpA5VYnEHovcA9Em5vNSuVUJk+tmx1 NRGD5hLePeyFOtPzIqu+Wy2AbDK+AwUoyjtApl1uwLJN1I2BZ/ugp2cpPG0W8hei7bxJ Rm9pKwG7MFnQVOEM5SxUTt+FmWWArAKp1FEp6uVn6VMgetBgWi9DEUvOoovqLRVO5337 y+4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=7OO0Cc/CqFvUueNFscLFtZltE+Jlu4wzyIBOB8CUx/I=; b=gaTLRcXsMqHcd8YIxmSjHKv1Y2jaCkZQI61U2+ZOqM+zk+sAbnlV+RtXLgxpE4szGl c6CQUzbMupS27iJT+CjsQ0QlMNySf8kuzqvFvrqZNJbq0+U5yRTYc67a3e6bqAwJY09U tOssdZGaMqZGvcwjpFKxgI20ZQV/3Sl729ZSxQucdc6jy1k40Bjj5EjE3rp82Hzlfnrb 92esvtDgIGzZvpIcFQIrOUxWc/yOFtINVYi5NpiQQfyLEbGYLY5Z5mj2fnP2UJ9cu8Dx Dfe/6i/wNkCADDpMNQ4nEdMfhLhtxZhfVSjfEkq5CH+owVQg63VerzAqTrMZYOsIz0DW 7wSw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y1si1251015edm.323.2019.09.17.06.08.50; Tue, 17 Sep 2019 06:09:17 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727715AbfIQNC5 (ORCPT + 99 others); Tue, 17 Sep 2019 09:02:57 -0400 Received: from mail.kernel.org ([198.145.29.99]:50372 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725902AbfIQNC5 (ORCPT ); Tue, 17 Sep 2019 09:02:57 -0400 Received: from gandalf.local.home (cpe-66-24-58-225.stny.res.rr.com [66.24.58.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 65B7C2171F; Tue, 17 Sep 2019 13:02:55 +0000 (UTC) Date: Tue, 17 Sep 2019 09:02:54 -0400 From: Steven Rostedt To: Petr Mladek Cc: Daniel Vetter , AndreaParri , Sergey Senozhatsky , Sergey Senozhatsky , Brendan Higgins , Paul Turner , Tetsuo Handa , Peter Zijlstra , John Ogness , Thomas Gleixner , LinusTorvalds , Greg Kroah-Hartman , Theodore Ts'o , PraritBhargava , LKML Subject: Re: printk meeting at LPC Message-ID: <20190917090254.46131564@gandalf.local.home> In-Reply-To: <20190917075216.agzoy6cnol5eio6y@pathway.suse.cz> References: <20190904123531.GA2369@hirez.programming.kicks-ass.net> <20190905130513.4fru6yvjx73pjx7p@pathway.suse.cz> <20190905143118.GP2349@hirez.programming.kicks-ass.net> <20190905121101.60c78422@oasis.local.home> <87k1acz5rx.fsf@linutronix.de> <20190916104624.n3jh363z37ah2kxa@pathway.suse.cz> <20190916094314.6053f988@gandalf.local.home> <20190917075216.agzoy6cnol5eio6y@pathway.suse.cz> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 17 Sep 2019 09:52:16 +0200 Petr Mladek wrote: > Heh, I did some grepping and the return value is actually used on > three locations: > > $> git grep "= printk(" > drivers/scsi/aic7xxx/aic79xx_core.c: printed = printk("%s[0x%x]", name, value); > drivers/scsi/aic7xxx/aic79xx_core.c: printed += printk(" "); > drivers/scsi/aic7xxx/aic79xx_core.c: printed += printk("%s%s", > drivers/scsi/aic7xxx/aic79xx_core.c: printed += printk(") "); > drivers/scsi/aic7xxx/aic79xx_core.c: printed += printk(" "); > drivers/scsi/aic7xxx/aic79xx_core.c: cur_col = printk("\n%3d FIFO_USE[0x%x] ", SCB_GET_TAG(scb), > drivers/scsi/aic7xxx/aic79xx_core.c: cur_col += printk("SHADDR = 0x%x%x, SHCNT = 0x%x ", > drivers/scsi/aic7xxx/aic79xx_core.c: cur_col += printk("HADDR = 0x%x%x, HCNT = 0x%x ", > drivers/scsi/aic7xxx/aic7xxx_core.c: printed = printk("%s[0x%x]", name, value); > drivers/scsi/aic7xxx/aic7xxx_core.c: printed += printk(" "); > drivers/scsi/aic7xxx/aic7xxx_core.c: printed += printk("%s%s", > drivers/scsi/aic7xxx/aic7xxx_core.c: printed += printk(") "); > drivers/scsi/aic7xxx/aic7xxx_core.c: printed += printk(" "); > drivers/scsi/aic7xxx/aic7xxx_core.c: cur_col = printk("\n%3d ", i); > drivers/scsi/aic7xxx/aic7xxx_core.c: cur_col = printk("\n%3d ", scb->hscb->tag); > drivers/scsi/libsas/sas_ata.c: r = printk("%s" SAS_FMT "ata%u: %s: %pV", > kernel/locking/lockdep.c: len += printk("%*s %s", depth, "", usage_str[bit]); > kernel/locking/lockdep.c: len += printk(KERN_CONT " at:\n"); > > It is probably not a big deal. For example, lockdep uses the value > just for formatting (extra spaces) when printing backtrace. > > I agree that it does not make sense to return the value if it > complicates the code too much. Well, we will need to count > the string length also from another reason (reservation). Well, it's being used. I was thinking of dropping it if it was not. Let's keep it then. Thanks for looking into this. -- Steve