summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPar-Gunnar Hjalmdahl <par-gunnar.p.hjalmdahl@stericsson.com>2011-08-31 20:03:17 +0530
committerPhilippe Langlais <philippe.langlais@stericsson.com>2012-05-22 11:05:52 +0200
commitde62262eef3eb2cdc3eff344b1cfe5c45851bdce (patch)
treebcf0391ce6e9e3de93793d81fa95f1b665ea6d0d
parentf05326611584d6d9e5b8bf1ac4853682181daaa6 (diff)
cg2900: Do not send RX data to wrong user
This patch corrects an issue where received data was sent to the wrong user depending on which user first opened the channel. ST-Ericsson Linux next: Not tested, ER 282957 ST-Ericsson ID: 333690 ST-Ericsson FOSS-OUT ID: Trivial Change-Id: I14c0bb64e2bd2c0d175da0407af3da179920d015 Signed-off-by: Par-Gunnar Hjalmdahl <par-gunnar.p.hjalmdahl@stericsson.com> Signed-off-by: Virupax Sadashivpetimath <virupax.sadashivpetimath@stericsson.com> Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/29927
-rw-r--r--drivers/staging/cg2900/mfd/cg2900_chip.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/staging/cg2900/mfd/cg2900_chip.c b/drivers/staging/cg2900/mfd/cg2900_chip.c
index fa243dcab15..9807b665efb 100644
--- a/drivers/staging/cg2900/mfd/cg2900_chip.c
+++ b/drivers/staging/cg2900/mfd/cg2900_chip.c
@@ -2075,10 +2075,15 @@ static void data_from_chip(struct cg2900_chip_dev *dev,
goto user_found;
}
- /* Search through the list of all open channels to find the user */
+ /*
+ * Search through the list of all open channels to find the user.
+ * We skip the audio channels since they have already been checked
+ * earlier in this function.
+ */
list_for_each(cursor, &info->open_channels) {
tmp = list_entry(cursor, struct cg2900_channel_item, list);
- if (tmp->user->h4_channel == h4_channel) {
+ if (tmp->user->h4_channel == h4_channel &&
+ !tmp->user->is_audio) {
user = tmp->user;
goto user_found;
}