mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
[NET] sunhme: Kill useless loop over sdevs in quattro_sbus_find().
Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
parent
c0442209e4
commit
96399487ad
1 changed files with 0 additions and 14 deletions
|
|
@ -2568,14 +2568,10 @@ static void __init quattro_apply_ranges(struct quattro *qp, struct happy_meal *h
|
|||
*/
|
||||
static struct quattro * __init quattro_sbus_find(struct sbus_dev *goal_sdev)
|
||||
{
|
||||
struct sbus_bus *sbus;
|
||||
struct sbus_dev *sdev;
|
||||
struct quattro *qp;
|
||||
int i;
|
||||
|
||||
if (qfe_sbus_list == NULL)
|
||||
goto found;
|
||||
|
||||
for (qp = qfe_sbus_list; qp != NULL; qp = qp->next) {
|
||||
for (i = 0, sdev = qp->quattro_dev;
|
||||
(sdev != NULL) && (i < 4);
|
||||
|
|
@ -2584,17 +2580,7 @@ static struct quattro * __init quattro_sbus_find(struct sbus_dev *goal_sdev)
|
|||
return qp;
|
||||
}
|
||||
}
|
||||
for_each_sbus(sbus) {
|
||||
for_each_sbusdev(sdev, sbus) {
|
||||
if (sdev == goal_sdev)
|
||||
goto found;
|
||||
}
|
||||
}
|
||||
|
||||
/* Cannot find quattro parent, fail. */
|
||||
return NULL;
|
||||
|
||||
found:
|
||||
qp = kmalloc(sizeof(struct quattro), GFP_KERNEL);
|
||||
if (qp != NULL) {
|
||||
int i;
|
||||
|
|
|
|||
Loading…
Reference in a new issue