Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1688008 > unrolled thread

[PATCH 2/4] firwmare: enable a debug print for batched requests

Started by"Luis R. Rodriguez" <mcgrof@kernel.org>
First post2017-07-15 23:20 +0200
Last post2017-07-17 16:40 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 2/4] firwmare: enable a debug print for batched requests "Luis R. Rodriguez" <mcgrof@kernel.org> - 2017-07-15 23:20 +0200
    Re: [PATCH 2/4] firwmare: enable a debug print for batched requests Greg KH <gregkh@linuxfoundation.org> - 2017-07-17 16:40 +0200

#1688008 — [PATCH 2/4] firwmare: enable a debug print for batched requests

From"Luis R. Rodriguez" <mcgrof@kernel.org>
Date2017-07-15 23:20 +0200
Subject[PATCH 2/4] firwmare: enable a debug print for batched requests
Message-ID<u3CDM-6wr-9@gated-at.bofh.it>
Otherwise there is no easy way this actually happened.

Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org>
---
 drivers/base/firmware_class.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/base/firmware_class.c b/drivers/base/firmware_class.c
index 6f58a15efa2b..a85dabeb1e20 100644
--- a/drivers/base/firmware_class.c
+++ b/drivers/base/firmware_class.c
@@ -334,6 +334,7 @@ static struct firmware_buf *__fw_lookup_buf(const char *fw_name)
 	return NULL;
 }
 
+/* Returns 1 for batching firmware requests with the same name */
 static int fw_lookup_and_allocate_buf(const char *fw_name,
 				      struct firmware_cache *fwc,
 				      struct firmware_buf **buf, void *dbuf,
@@ -347,6 +348,7 @@ static int fw_lookup_and_allocate_buf(const char *fw_name,
 		kref_get(&tmp->ref);
 		spin_unlock(&fwc->lock);
 		*buf = tmp;
+		pr_debug("batched request - sharing the same struct firmware_buf and lookup for multiple requests\n");
 		return 1;
 	}
 	tmp = __allocate_fw_buf(fw_name, fwc, dbuf, size);
-- 
2.11.0

[toc] | [next] | [standalone]


#1689125

FromGreg KH <gregkh@linuxfoundation.org>
Date2017-07-17 16:40 +0200
Message-ID<u4flO-6ht-55@gated-at.bofh.it>
In reply to#1688008
On Sat, Jul 15, 2017 at 02:18:51PM -0700, Luis R. Rodriguez wrote:
> Otherwise there is no easy way this actually happened.
> 
> Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org>

You misspelled "firmware" in the subject :(

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web