Skip to content

Commit 20f868d

Browse files
committed
Merge tag 'rpmsg-v6.18' of git://git.kernel.org/pub/scm/linux/kernel/git/remoteproc/linux
Pull rpmsg updates from Bjorn Andersson: - Clean up the dev_pm_domain integration in rpmsg core. Correct module aliases for the rpmsg char driver. - Transition Qualcomm SMD and GLINK drivers to strscpy() and fix the regression in legacy code for acquiring outgoing interrupts using the non-mailbox based mechanism. * tag 'rpmsg-v6.18' of git://git.kernel.org/pub/scm/linux/kernel/git/remoteproc/linux: rpmsg: qcom_smd: Fix fallback to qcom,ipc parse rpmsg: Use strscpy() instead of strscpy_pad() rpmsg: core: Drop dev_pm_domain_detach() call rpmsg: char: Export alias for RPMSG ID rpmsg-raw from table
2 parents c35f902 + 09390ed commit 20f868d

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

drivers/rpmsg/qcom_glink_native.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1663,7 +1663,7 @@ static int qcom_glink_rx_open(struct qcom_glink *glink, unsigned int rcid,
16631663
}
16641664

16651665
rpdev->ept = &channel->ept;
1666-
strscpy_pad(rpdev->id.name, name, RPMSG_NAME_SIZE);
1666+
strscpy(rpdev->id.name, name);
16671667
rpdev->src = RPMSG_ADDR_ANY;
16681668
rpdev->dst = RPMSG_ADDR_ANY;
16691669
rpdev->ops = &glink_device_ops;

drivers/rpmsg/qcom_smd.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1089,7 +1089,7 @@ static int qcom_smd_create_device(struct qcom_smd_channel *channel)
10891089

10901090
/* Assign public information to the rpmsg_device */
10911091
rpdev = &qsdev->rpdev;
1092-
strscpy_pad(rpdev->id.name, channel->name, RPMSG_NAME_SIZE);
1092+
strscpy(rpdev->id.name, channel->name);
10931093
rpdev->src = RPMSG_ADDR_ANY;
10941094
rpdev->dst = RPMSG_ADDR_ANY;
10951095

@@ -1368,7 +1368,7 @@ static int qcom_smd_parse_edge(struct device *dev,
13681368
edge->mbox_client.knows_txdone = true;
13691369
edge->mbox_chan = mbox_request_channel(&edge->mbox_client, 0);
13701370
if (IS_ERR(edge->mbox_chan)) {
1371-
if (PTR_ERR(edge->mbox_chan) != -ENODEV) {
1371+
if (PTR_ERR(edge->mbox_chan) != -ENOENT) {
13721372
ret = dev_err_probe(dev, PTR_ERR(edge->mbox_chan),
13731373
"failed to acquire IPC mailbox\n");
13741374
goto put_node;

drivers/rpmsg/rpmsg_char.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -522,8 +522,10 @@ static void rpmsg_chrdev_remove(struct rpmsg_device *rpdev)
522522

523523
static struct rpmsg_device_id rpmsg_chrdev_id_table[] = {
524524
{ .name = "rpmsg-raw" },
525+
{ .name = "rpmsg_chrdev" },
525526
{ },
526527
};
528+
MODULE_DEVICE_TABLE(rpmsg, rpmsg_chrdev_id_table);
527529

528530
static struct rpmsg_driver rpmsg_chrdev_driver = {
529531
.probe = rpmsg_chrdev_probe,
@@ -565,6 +567,5 @@ static void rpmsg_chrdev_exit(void)
565567
}
566568
module_exit(rpmsg_chrdev_exit);
567569

568-
MODULE_ALIAS("rpmsg:rpmsg_chrdev");
569570
MODULE_DESCRIPTION("RPMSG device interface");
570571
MODULE_LICENSE("GPL v2");

drivers/rpmsg/rpmsg_core.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -479,7 +479,8 @@ static int rpmsg_dev_probe(struct device *dev)
479479
struct rpmsg_endpoint *ept = NULL;
480480
int err;
481481

482-
err = dev_pm_domain_attach(dev, PD_FLAG_ATTACH_POWER_ON);
482+
err = dev_pm_domain_attach(dev, PD_FLAG_ATTACH_POWER_ON |
483+
PD_FLAG_DETACH_POWER_OFF);
483484
if (err)
484485
goto out;
485486

@@ -538,8 +539,6 @@ static void rpmsg_dev_remove(struct device *dev)
538539
if (rpdrv->remove)
539540
rpdrv->remove(rpdev);
540541

541-
dev_pm_domain_detach(dev, true);
542-
543542
if (rpdev->ept)
544543
rpmsg_destroy_ept(rpdev->ept);
545544
}

0 commit comments

Comments
 (0)