~ubuntu-branches/ubuntu/precise/linux-ti-omap4/precise

« back to all changes in this revision

Viewing changes to arch/arm/mach-pxa/am300epd.c

  • Committer: Bazaar Package Importer
  • Author(s): Paolo Pisati
  • Date: 2011-06-29 15:23:51 UTC
  • mfrom: (26.1.1 natty-proposed)
  • Revision ID: james.westby@ubuntu.com-20110629152351-xs96tm303d95rpbk
Tags: 3.0.0-1200.2
* Rebased against 3.0.0-6.7
* BSP from TI based on 3.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
125
125
                if (err) {
126
126
                        dev_err(&am300_device->dev, "failed requesting "
127
127
                                "gpio %d, err=%d\n", i, err);
128
 
                        while (i >= DB0_GPIO_PIN)
129
 
                                gpio_free(i--);
130
 
                        i = ARRAY_SIZE(gpios) - 1;
131
 
                        goto err_req_gpio;
 
128
                        goto err_req_gpio2;
132
129
                }
133
130
        }
134
131
 
159
156
 
160
157
        return 0;
161
158
 
 
159
err_req_gpio2:
 
160
        while (--i >= DB0_GPIO_PIN)
 
161
                gpio_free(i);
 
162
        i = ARRAY_SIZE(gpios);
162
163
err_req_gpio:
163
 
        while (i > 0)
164
 
                gpio_free(gpios[i--]);
 
164
        while (--i >= 0)
 
165
                gpio_free(gpios[i]);
165
166
 
166
167
        return err;
167
168
}