staging: most: cdev: remove noisy log messages
This patch removes unnecessary log messages to avoid noise in the kernel log. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Link: https://lore.kernel.org/r/1592815695-19305-2-git-send-email-christian.gromm@microchip.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
bcb24e6d32
commit
61fd971edd
|
@ -129,19 +129,16 @@ static int comp_open(struct inode *inode, struct file *filp)
|
||||||
((filp->f_flags & O_ACCMODE) != O_RDONLY)) ||
|
((filp->f_flags & O_ACCMODE) != O_RDONLY)) ||
|
||||||
((c->cfg->direction == MOST_CH_TX) &&
|
((c->cfg->direction == MOST_CH_TX) &&
|
||||||
((filp->f_flags & O_ACCMODE) != O_WRONLY))) {
|
((filp->f_flags & O_ACCMODE) != O_WRONLY))) {
|
||||||
pr_info("WARN: Access flags mismatch\n");
|
|
||||||
return -EACCES;
|
return -EACCES;
|
||||||
}
|
}
|
||||||
|
|
||||||
mutex_lock(&c->io_mutex);
|
mutex_lock(&c->io_mutex);
|
||||||
if (!c->dev) {
|
if (!c->dev) {
|
||||||
pr_info("WARN: Device is destroyed\n");
|
|
||||||
mutex_unlock(&c->io_mutex);
|
mutex_unlock(&c->io_mutex);
|
||||||
return -ENODEV;
|
return -ENODEV;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (c->access_ref) {
|
if (c->access_ref) {
|
||||||
pr_info("WARN: Device is busy\n");
|
|
||||||
mutex_unlock(&c->io_mutex);
|
mutex_unlock(&c->io_mutex);
|
||||||
return -EBUSY;
|
return -EBUSY;
|
||||||
}
|
}
|
||||||
|
@ -328,10 +325,8 @@ static int comp_disconnect_channel(struct most_interface *iface, int channel_id)
|
||||||
{
|
{
|
||||||
struct comp_channel *c;
|
struct comp_channel *c;
|
||||||
|
|
||||||
if (!iface) {
|
if (!iface)
|
||||||
pr_info("Bad interface pointer\n");
|
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
|
||||||
|
|
||||||
c = get_channel(iface, channel_id);
|
c = get_channel(iface, channel_id);
|
||||||
if (!c)
|
if (!c)
|
||||||
|
@ -397,10 +392,9 @@ static int comp_tx_completion(struct most_interface *iface, int channel_id)
|
||||||
{
|
{
|
||||||
struct comp_channel *c;
|
struct comp_channel *c;
|
||||||
|
|
||||||
if (!iface) {
|
if (!iface)
|
||||||
pr_info("Bad interface pointer\n");
|
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
|
||||||
if ((channel_id < 0) || (channel_id >= iface->num_channels)) {
|
if ((channel_id < 0) || (channel_id >= iface->num_channels)) {
|
||||||
pr_info("Channel ID out of range\n");
|
pr_info("Channel ID out of range\n");
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
@ -432,10 +426,9 @@ static int comp_probe(struct most_interface *iface, int channel_id,
|
||||||
int retval;
|
int retval;
|
||||||
int current_minor;
|
int current_minor;
|
||||||
|
|
||||||
if ((!iface) || (!cfg) || (!name)) {
|
if ((!iface) || (!cfg) || (!name))
|
||||||
pr_info("Probing component with bad arguments");
|
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
|
||||||
c = get_channel(iface, channel_id);
|
c = get_channel(iface, channel_id);
|
||||||
if (c)
|
if (c)
|
||||||
return -EEXIST;
|
return -EEXIST;
|
||||||
|
@ -474,7 +467,6 @@ static int comp_probe(struct most_interface *iface, int channel_id,
|
||||||
|
|
||||||
if (IS_ERR(c->dev)) {
|
if (IS_ERR(c->dev)) {
|
||||||
retval = PTR_ERR(c->dev);
|
retval = PTR_ERR(c->dev);
|
||||||
pr_info("failed to create new device node %s\n", name);
|
|
||||||
goto err_free_kfifo_and_del_list;
|
goto err_free_kfifo_and_del_list;
|
||||||
}
|
}
|
||||||
kobject_uevent(&c->dev->kobj, KOBJ_ADD);
|
kobject_uevent(&c->dev->kobj, KOBJ_ADD);
|
||||||
|
@ -507,13 +499,9 @@ static int __init mod_init(void)
|
||||||
{
|
{
|
||||||
int err;
|
int err;
|
||||||
|
|
||||||
pr_info("init()\n");
|
|
||||||
|
|
||||||
comp.class = class_create(THIS_MODULE, "most_cdev");
|
comp.class = class_create(THIS_MODULE, "most_cdev");
|
||||||
if (IS_ERR(comp.class)) {
|
if (IS_ERR(comp.class))
|
||||||
pr_info("No udev support.\n");
|
|
||||||
return PTR_ERR(comp.class);
|
return PTR_ERR(comp.class);
|
||||||
}
|
|
||||||
|
|
||||||
INIT_LIST_HEAD(&channel_list);
|
INIT_LIST_HEAD(&channel_list);
|
||||||
spin_lock_init(&ch_list_lock);
|
spin_lock_init(&ch_list_lock);
|
||||||
|
@ -545,8 +533,6 @@ static void __exit mod_exit(void)
|
||||||
{
|
{
|
||||||
struct comp_channel *c, *tmp;
|
struct comp_channel *c, *tmp;
|
||||||
|
|
||||||
pr_info("exit module\n");
|
|
||||||
|
|
||||||
most_deregister_configfs_subsys(&comp.cc);
|
most_deregister_configfs_subsys(&comp.cc);
|
||||||
most_deregister_component(&comp.cc);
|
most_deregister_component(&comp.cc);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue