Bug 476355 - Camera inaccessible - PTP errors (used to work fine on older Fedoras)
Summary: Camera inaccessible - PTP errors (used to work fine on older Fedoras)
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: gphoto2
Version: 10
Hardware: All
OS: Linux
low
urgent
Target Milestone: ---
Assignee: Jindrich Novy
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-12-13 13:47 UTC by An. N
Modified: 2015-02-12 07:34 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-12-18 07:16:55 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
gphoto2 error log (20.80 KB, text/plain)
2008-12-13 13:48 UTC, An. N
no flags Details
gphoto2 debug log (289.38 KB, text/plain)
2008-12-21 19:26 UTC, Jonathan Kamens
no flags Details
gphoto2 error log (2.4.4) (20.76 KB, text/plain)
2009-02-01 23:39 UTC, An. N
no flags Details
Patch to change canon timeout values (1.06 KB, application/octet-stream)
2009-03-31 18:51 UTC, Russell Harrison
no flags Details

Description An. N 2008-12-13 13:47:53 UTC
Description of problem:
When plugging in a digital camera, I get the error:

"Unable to mount <cameraname> (PTP mode). Error initializing camera: -1: Unspecified error"

The camera appears in nautilus but is inaccessible.. This used to work on Fedora 6 and Fedora 7 with the same hardware and the same digital camera.

I've attached a log of "env LANG=C gphoto2 --debug --debug-logfile=my-logfile.txt -l"


Version-Release number of selected component (if applicable):
libgphoto2-2.4.3-1.fc10.i386
glibgphoto2-devel-2.4.3-1.fc10.i386
gvfs-gphoto2-1.0.3-1.fc10.i386
gphoto2-2.4.3-1.fc10.i386
gvfs-1.0.3-1.fc10.i386

How reproducible:
Always

Steps to Reproduce:
1. Plug in a digital camera via USB (in my case canon Ixus 50)
2.
3.
  
Actual results:
The mentioned error message is displayed

Expected results:
Camera is mounted and works ok

Additional info:
usb 2-4: new high speed USB device using ehci_hcd and address 7
usb 2-4: configuration #1 chosen from 1 choice
usb 2-4: New USB device found, idVendor=04a9, idProduct=310e
usb 2-4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
usb 2-4: Product: Canon Digital Camera
usb 2-4: Manufacturer: Canon Inc.

Bus 002 Device 008: ID 04a9:310e Canon, Inc. Digital IXUS 50 (PTP mode)

Comment 1 An. N 2008-12-13 13:48:41 UTC
Created attachment 326817 [details]
gphoto2 error log

Comment 2 Vaclav "sHINOBI" Misek 2008-12-14 11:24:55 UTC
Can you try to update gvfs and gvfs-gphoto2 from updates-testing? With these versions it seems to be working for me, although with different camera model.

Comment 3 An. N 2008-12-14 16:36:01 UTC
It doesn't work with those packages from updates-testing. I think that gphoto2 doesn't communicate with the camera properly so this is most likely not a gvfs specific bug.

Comment 4 Vaclav "sHINOBI" Misek 2008-12-15 17:50:51 UTC
Please can you try to download images with the root privileges? In the past I have similar experience and when su - and gthumb I was able to import images correctly. Thanks a lot.

Comment 5 An. N 2008-12-15 22:36:44 UTC
Have you read the description and error log that I have provided?

This is not a privilege problem, this is a communication problem at the protocol level. Citing from the log:

2.170189 ptp2/usbread(2): Clearing halt on IN EP and retrying once.
2.170318 gphoto2-port(2): Clear halt...
2.389947 ptp2/usb_getresp(0): request code 0x1002 getting resp error 0x02ff
2.390131 ptp2/camera_init(0): ptp_opensession returns 2ff
2.390158 ptp2/device_reset_request(2): sending reset
2.390183 gphoto2-port(2): Writing message (request=0x66 value=0x0 index=0x0 size=0=0x0)...
2.390214 gphoto2-port(3): No hexdump (NULL buffer)
2.489467 context(0): PTP I/O error
2.489608 gphoto2-port(2): Closing port...
2.491759 context(0): An error occurred in the io-library ('Unspecified error'): No error description available

To be absolutely sure I tried your suggestion and no - it did not work. The application returns this error:

"An error occurred in the io-library ('Unspecified error'): No error description available"

Comment 6 Vaclav "sHINOBI" Misek 2008-12-16 06:01:49 UTC
Yes, I read it, but I just wanted to be absolutely sure it's not this problem as the privilege problem behaved quite the same way.

Comment 7 Jonathan Kamens 2008-12-21 19:26:19 UTC
Also broken in rawhide with Canon Powershot A710 IS.  Will attach gphoto2 debug log.

Comment 8 Jonathan Kamens 2008-12-21 19:26:50 UTC
Created attachment 327592 [details]
gphoto2 debug log

Comment 9 Jonathan Kamens 2008-12-21 19:31:05 UTC
Tried downgrading to gphoto2 from Fedora 9, but it didn't solve the problem, so I assume that the problem is not in gphoto2 itself but rather in something lower in the food chain.

Comment 10 An. N 2009-01-30 21:44:24 UTC
Is there any news on this bug? It's been over 6 weeks and it's REALLY annoying when your desktop system can't do the basic things properly...

Is any other information needed?

Comment 11 Jindrich Novy 2009-01-31 08:33:50 UTC
gphoto2 and libgphoto2 is now recently updated to 2.4.4. It contains many fixes. Could you give it a try? I could then release Fedora updates for 9,10.

Comment 12 James 2009-01-31 17:25:33 UTC
(In reply to comment #11)
> gphoto2 and libgphoto2 is now recently updated to 2.4.4. It contains many
> fixes. Could you give it a try? I could then release Fedora updates for 9,10.

Please submit Fedora 10 builds for these to Koji for testing, there are only Fedora 11 packages there at the moment.

Comment 13 Jindrich Novy 2009-02-01 09:02:02 UTC
Here is the F10 libgphoto2:
http://koji.fedoraproject.org/koji/taskinfo?taskID=1097023

and here the F9 one:
http://koji.fedoraproject.org/koji/taskinfo?taskID=1097028

Comment 14 An. N 2009-02-01 23:38:41 UTC
No improvement, same error (I'm referring to the rpm from koji). What do you suggest that we do?

libgphoto2-2.4.4-1.fc10.i386

Comment 15 An. N 2009-02-01 23:39:28 UTC
Created attachment 330564 [details]
gphoto2 error log (2.4.4)

Comment 16 Jindrich Novy 2009-02-02 08:03:28 UTC
Upstream suggests to upgrade to kernel 2.6.28.1 or better. It is not directly (lib)gphoto2 fault, but kernel failure:

http://www.nabble.com/IXUS-40-is-autodetected,-but-PTP-error-td21525285.html

Comment 17 Marcus Meissner 2009-02-02 08:12:59 UTC
2.6.28 and 2.6.28.1 are known bad.

2.6.28.2 should be good again

Comment 18 An. N 2009-02-02 16:07:01 UTC
The kernel I was using was 2.6.27.7-134.fc10.i686. I take it that it's broken as well?

Anyway, shouldn't this be filed as a bug against the Fedora kernel then?

Thanks.

Comment 19 An. N 2009-02-02 19:41:59 UTC
I've checked this with 2.6.28.2 - doesn't work, same symptoms.

Either 2.6.28.2 is also affected, or it's not a kernel issue?

Comment 20 Jindrich Novy 2009-02-03 10:45:40 UTC
Ok, reopening until we are completely sure it is not a bug of (lib)gphoto2.

Comment 21 An. N 2009-02-22 00:51:12 UTC
It seems that the authors don't think it's a kernel issue. Should I be bugging them or you about this, then?

My camera still doesn't work in Linux.

Comment 22 An. N 2009-02-22 14:04:32 UTC
I manually changed the canon ptp2 timeout to 1500 (and another timeout in the canon lib from 175 to 500)
recompiled, reinstalled

Seems to work now. Self-support is the way to go I guess :-(

There's still a bug in fedora gphoto2 as far as I'm concerned, though.

Comment 23 Marcus Meissner 2009-02-22 17:43:39 UTC
which time out exactly?

if you mail me the lines I integrate ity upstream.

Comment 24 Marcus Meissner 2009-02-25 22:33:19 UTC
i guessed and have applied both changes to libgphoto2 upstream.

Comment 25 An. N 2009-02-27 13:30:07 UTC
Sorry for the late reply.

Here are the changes:
I'm not so sure about the first one.

camlibs/canon/usb.c:
//#define CANON_FAST_TIMEOUT 175
#define CANON_FAST_TIMEOUT 500

camlibs/ptp2/library.c:
#define USB_CANON_START_TIMEOUT 1500    /* 0.5 seconds */

Comment 26 Russell Harrison 2009-03-31 18:51:03 UTC
Created attachment 337388 [details]
Patch to change canon timeout values

I rebuilt libgphoto2 changing the values in this bug and can confirm they do fix the problem with my camera.  This is the patch file I used to rebuild the rpm and could be used to fix the problem until the next upstream version is out with the fix.

Comment 27 Fedora Update System 2009-04-01 13:33:25 UTC
libgphoto2-2.4.4-1.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/libgphoto2-2.4.4-1.fc10

Comment 28 Jindrich Novy 2009-04-01 13:44:44 UTC
Applied in rawhide and testing updates to F10 are prepared. Please test it and give it positive carma so that they get moved to stable :) Thanks.

https://admin.fedoraproject.org/updates/libgphoto2-2.4.4-1.fc10

Comment 29 Jindrich Novy 2009-04-02 05:05:00 UTC
Please disregard this update. We would break gphoto2-2.4.3 in F10 if we release libgphoto2-2.4.4 and koji says that chain builds are not enabled for dist-f10-updates-candidate :/ so it doesn't seem to be possible to build gphoto2-2.4.4 on top of it and release update.

Comment 30 Tore Anderson 2009-04-18 21:16:24 UTC
I have an Canon IXUS 800 IS and experienced this error today, for the first time.

Applying Andrzej Nowak's changes successfully works around the problem.  The actual cause seems to have been that the memory card had too many pictures on it for the camera to respond in time - after inserting another memory card with few pictures on it the unpatched version worked fine again.

Tore

Comment 31 Duncan Innes 2009-08-19 20:43:56 UTC
Have a Canon PowerShot G9 and have experienced this error with several versions of Fedora including a fresh install of F11 today.  The install was done with the internet repositories enabled, and all updates have been applied.

Have done the chmod 777 /dev/bus/usb fix and it's working.

But this is getting really silly.  Is there something upstream that doesn't know about one of the most obvious uses of Linux (connecting to home digital cameras) failing at the first hurdle?

Just to confirm - this bug still exists in the latest F11 code.  Changing the directory permissions of /dev/bus/usb allows things to work for the moment.

Duncan

Comment 32 Jindrich Novy 2009-08-20 05:57:22 UTC
Any luck with the new libgphoto2-2.4.7 ?

http://koji.fedoraproject.org/koji/taskinfo?taskID=1616389

Comment 33 Bug Zapper 2009-11-18 09:26:55 UTC
This message is a reminder that Fedora 10 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 10.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '10'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 10's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 10 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 34 Bug Zapper 2009-12-18 07:16:55 UTC
Fedora 10 changed to end-of-life (EOL) status on 2009-12-17. Fedora 10 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.

Comment 35 Turgut Kalfaoglu 2015-02-12 07:34:08 UTC
LOL -- same error, Fedora 21!


Note You need to log in before you can comment on or make changes to this bug.