-
Notifications
You must be signed in to change notification settings - Fork 136
Fix/upstream reviews3 #411
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix/upstream reviews3 #411
Conversation
sound/soc/sof/intel/hda-dai.c: In function ‘hda_link_hw_free’: sound/soc/sof/intel/hda-dai.c:213:22: warning: variable ‘sdev’ set but not used [-Wunused-but-set-variable] struct snd_sof_dev *sdev; ^~~~ Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
sound/soc/sof/debug.c: In function ‘sof_dfsentry_read’: sound/soc/sof/debug.c:62:10: warning: comparison of unsigned expression < 0 is always false [-Wtype-limits] if (ret < 0) Defining a 'ret' variable as size_t was borderline criminal in the first place... Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
sound/soc/sof/topology.c: In function ‘sof_control_load_volume’: sound/soc/sof/topology.c:261:28: warning: variable ‘cdata’ set but not used [-Wunused-but-set-variable] struct sof_ipc_ctrl_data *cdata; ^~~~~ sound/soc/sof/topology.c: In function ‘snd_sof_load_topology’: sound/soc/sof/topology.c:2711:27: warning: variable ‘hdr’ set but not used [-Wunused-but-set-variable] struct snd_soc_tplg_hdr *hdr; ^~~ Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Constants with _MS suffix simplification of search loop Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Not used, remove for now Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Feedback from Andy Shevchenko Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Unclear if platform_device_register_data can return NULL, err on the side of caution Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Suggested by Andy Shevchenko Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
@plbossart you're not alone :) I will prioritize this for tonight |
sound/soc/sof/sof-spi-dev.c
Outdated
@@ -22,12 +22,14 @@ | |||
#include "hw-spi.h" | |||
#include "ops.h" | |||
|
|||
#if 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why "#if 0", can this part be just deleted?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can delete this, and add it back when PM on it is supported.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor comments.
sound/soc/sof/sof-spi-dev.c
Outdated
@@ -22,12 +22,14 @@ | |||
#include "hw-spi.h" | |||
#include "ops.h" | |||
|
|||
#if 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can delete this, and add it back when PM on it is supported.
sound/soc/sof/debug.c
Outdated
@@ -41,11 +41,11 @@ static ssize_t sof_dfsentry_read(struct file *file, char __user *buffer, | |||
return -EINVAL; | |||
if (pos >= size || !count) | |||
return 0; | |||
if (count > size - pos) | |||
if (count > size - pos) /* type warnings with min(), use test */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
count = min(count, (size_t) (size - pos)); ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done, thanks
Maybe there are other cases where this is needed Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
SI units people. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Feedback from Andy Shevchenko Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Feedback from Andy Shevchenko. Keep indent on for subparts of the log Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
remove change variable, use return false/true instead Feedback from Andy Shevchenko Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
remove new line, even if it makes checkpatch unhappy Feedback from Andy Shevchenko Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Feedback from Andy Shevchenko Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
remove spi_pm, will be added back when needed Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Apparently cannot be unsigned int Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
abab6fb
to
729fb17
Compare
This PR addresses most of the feedback from @andy-shev (Andy Shevchenko) on the core parts only.
Reviewers, I would appreciate if you can prioritize and spend a bit of time double-checking the fixes. Also there are 4 issues I added when I don't have the answers on my own.
I realize this is painful work, but I have no intention of doing it alone while you have fun with real work... I will merge these fixes on Thursday latest to get a chance for one round of validation before the next batch.
Thank you.
-Pierre