Merge tag 'rpmsg-v5.4' of git://git.kernel.org/pub/scm/linux/kernel/git/andersson/remoteproc
Pull rpmsg updates from Bjorn Andersson: "This contains updates to make the rpmsg sample driver more useful, fixes the naming of GLINK devices to avoid naming collisions and a few minor bug fixes. It also updates MAINTAINERS to reflect the move to kernel.org" * tag 'rpmsg-v5.4' of git://git.kernel.org/pub/scm/linux/kernel/git/andersson/remoteproc: rpmsg: glink-smem: Name the edge based on parent remoteproc rpmsg: glink: Use struct_size() helper rpmsg: virtio_rpmsg_bus: replace "%p" with "%pK" MAINTAINERS: rpmsg: fix git tree location rpmsg: core: fix comments samples/rpmsg: Introduce a module parameter for message count samples/rpmsg: Replace print_hex_dump() with print_hex_dump_debug()
This commit is contained in:
@@ -14,7 +14,9 @@
|
||||
#include <linux/rpmsg.h>
|
||||
|
||||
#define MSG "hello world!"
|
||||
#define MSG_LIMIT 100
|
||||
|
||||
static int count = 100;
|
||||
module_param(count, int, 0644);
|
||||
|
||||
struct instance_data {
|
||||
int rx_count;
|
||||
@@ -29,11 +31,11 @@ static int rpmsg_sample_cb(struct rpmsg_device *rpdev, void *data, int len,
|
||||
dev_info(&rpdev->dev, "incoming msg %d (src: 0x%x)\n",
|
||||
++idata->rx_count, src);
|
||||
|
||||
print_hex_dump(KERN_DEBUG, __func__, DUMP_PREFIX_NONE, 16, 1,
|
||||
data, len, true);
|
||||
print_hex_dump_debug(__func__, DUMP_PREFIX_NONE, 16, 1, data, len,
|
||||
true);
|
||||
|
||||
/* samples should not live forever */
|
||||
if (idata->rx_count >= MSG_LIMIT) {
|
||||
if (idata->rx_count >= count) {
|
||||
dev_info(&rpdev->dev, "goodbye!\n");
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user