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

« back to all changes in this revision

Viewing changes to drivers/net/usb/plusb.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:
45
45
 * seems to get wedged under load.  Prolific docs are weak, and
46
46
 * don't identify differences between PL2301 and PL2302, much less
47
47
 * anything to explain the different PL2302 versions observed.
 
48
 *
 
49
 * NOTE:  pl2501 has several modes, including pl2301 and pl2302
 
50
 * compatibility.   Some docs suggest the difference between 2301
 
51
 * and 2302 is only to make MS-Windows use a different driver...
 
52
 *
 
53
 * pl25a1 glue based on patch from Tony Gibbs.  Prolific "docs" on
 
54
 * this chip are as usual incomplete about what control messages
 
55
 * are supported.
48
56
 */
49
57
 
50
58
/*
86
94
 
87
95
static int pl_reset(struct usbnet *dev)
88
96
{
 
97
        int status;
 
98
 
89
99
        /* some units seem to need this reset, others reject it utterly.
90
100
         * FIXME be more like "naplink" or windows drivers.
91
101
         */
92
 
        (void) pl_set_QuickLink_features(dev,
 
102
        status = pl_set_QuickLink_features(dev,
93
103
                PL_S_EN|PL_RESET_OUT|PL_RESET_IN|PL_PEER_E);
 
104
        if (status != 0 && netif_msg_probe(dev))
 
105
                netif_dbg(dev, link, dev->net, "pl_reset --> %d\n", status);
94
106
        return 0;
95
107
}
96
108
 
97
109
static const struct driver_info prolific_info = {
98
 
        .description =  "Prolific PL-2301/PL-2302",
 
110
        .description =  "Prolific PL-2301/PL-2302/PL-25A1",
99
111
        .flags =        FLAG_POINTTOPOINT | FLAG_NO_SETINT,
100
112
                /* some PL-2302 versions seem to fail usb_set_interface() */
101
113
        .reset =        pl_reset,
111
123
 
112
124
static const struct usb_device_id       products [] = {
113
125
 
 
126
/* full speed cables */
114
127
{
115
128
        USB_DEVICE(0x067b, 0x0000),     // PL-2301
116
129
        .driver_info =  (unsigned long) &prolific_info,
119
132
        .driver_info =  (unsigned long) &prolific_info,
120
133
},
121
134
 
 
135
/* high speed cables */
 
136
{
 
137
        USB_DEVICE(0x067b, 0x25a1),     /* PL-25A1, no eeprom */
 
138
        .driver_info =  (unsigned long) &prolific_info,
 
139
}, {
 
140
        USB_DEVICE(0x050d, 0x258a),     /* Belkin F5U258/F5U279 (PL-25A1) */
 
141
        .driver_info =  (unsigned long) &prolific_info,
 
142
},
 
143
 
122
144
        { },            // END
123
145
};
124
146
MODULE_DEVICE_TABLE(usb, products);
134
156
 
135
157
static int __init plusb_init(void)
136
158
{
137
 
        return usb_register(&plusb_driver);
 
159
        return usb_register(&plusb_driver);
138
160
}
139
161
module_init(plusb_init);
140
162
 
141
163
static void __exit plusb_exit(void)
142
164
{
143
 
        usb_deregister(&plusb_driver);
 
165
        usb_deregister(&plusb_driver);
144
166
}
145
167
module_exit(plusb_exit);
146
168
 
147
169
MODULE_AUTHOR("David Brownell");
148
 
MODULE_DESCRIPTION("Prolific PL-2301/2302 USB Host to Host Link Driver");
 
170
MODULE_DESCRIPTION("Prolific PL-2301/2302/25A1 USB Host to Host Link Driver");
149
171
MODULE_LICENSE("GPL");