quick hack to make my powershot s40 work

ok markus@
This commit is contained in:
jcs 2002-08-21 13:38:49 +00:00
parent d8d38b6001
commit 6c4a99ab01
2 changed files with 36 additions and 14 deletions

View File

@ -1,16 +1,27 @@
$OpenBSD: patch-usb_c,v 1.1 2002/07/06 16:32:16 fgsch Exp $
--- usb.c.orig Sat Jul 6 12:20:18 2002
+++ usb.c Sat Jul 6 12:25:03 2002
@@ -91,6 +91,12 @@ int USB_camera_init(struct usb_device **
printf("Canon S100 found\n");
return USB_INIT_S100;
$OpenBSD: patch-usb_c,v 1.2 2002/08/21 13:38:49 jcs Exp $
--- usb.c.orig Tue Mar 13 07:46:18 2001
+++ usb.c Sat Aug 17 16:01:52 2002
@@ -84,11 +84,23 @@
printf("Canon S20 found\n");
return USB_INIT_S20;
break;
+ case PRODUCT_ID_S40:
+ *camera_dev = dev;
+ if (opt_debug)
+ printf("Canon S40 found\n");
+ return USB_INIT_S40;
+ break;
case PRODUCT_ID_S100_EU:
case PRODUCT_ID_S100_US:
*camera_dev = dev;
if (opt_debug)
printf("Canon S100 found\n");
+ return USB_INIT_S100;
+ break;
+ case PRODUCT_ID_S200:
+ *camera_dev = dev;
+ if (opt_debug)
+ printf("Canon S200 found\n");
+ return USB_INIT_S100;
+ break;
return USB_INIT_S100;
break;
case PRODUCT_ID_G1:
*camera_dev = dev;
if (opt_debug)

View File

@ -1,7 +1,18 @@
$OpenBSD: patch-usb_h,v 1.1 2002/07/06 16:32:16 fgsch Exp $
--- usb.h.orig Sat Jul 6 12:20:22 2002
+++ usb.h Sat Jul 6 12:24:55 2002
@@ -28,6 +28,7 @@
$OpenBSD: patch-usb_h,v 1.2 2002/08/21 13:38:49 jcs Exp $
--- usb.h.orig Tue Mar 13 07:46:18 2001
+++ usb.h Sat Aug 17 16:02:27 2002
@@ -19,15 +19,18 @@
#define USB_INIT_S20 2 /* S20 found */
#define USB_INIT_S100 3 /* S100 (Digital Ixus) found */
#define USB_INIT_G1 4 /* G1 found */
+#define USB_INIT_S40 5 /* S40 found */
#define USB_INIT_NEW 100 /* Unsupported PowerShot found! */
#define USB_INIT_FAILED -1 /* Unable to initialize USB */
#define VENDOR_ID_CANON 0x04A9
#define PRODUCT_ID_S10 0x3041 /* PowerShot S10 */
#define PRODUCT_ID_S20 0x3043 /* PowerShot S20 */
+#define PRODUCT_ID_S40 0x3056 /* PowerShot S40 */
#define PRODUCT_ID_S100_US 0x3045 /* S100, aka. Digital Ixus, Elph */
#define PRODUCT_ID_S100_EU 0x3047 /* S100, aka. Digital Ixus, Elph */
#define PRODUCT_ID_G1 0x3048 /* PowerShot G1 */