Bug 205721

Summary: fmio uses direct port IO when it shouldn't
Product: [Fedora] Fedora Reporter: Andy Shevchenko <andy>
Component: fmioAssignee: Andy Shevchenko <andy>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: extras-qa
Target Milestone: ---   
Target Release: ---   
Hardware: powerpc   
OS: Linux   
Whiteboard:
Fixed In Version: 2.0.8-10.fc7 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-11-17 05:35:18 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 179260    

Description Andy Shevchenko 2006-09-08 08:17:12 UTC
Description of problem:
The PPC build is broken due to some source isn't correct for PPC headers.

...
make[1]: Entering directory `/builddir/build/BUILD/fmio-2.0.8/src'
make[1]: warning: jobserver unavailable: using -j1.  Add `+' to parent make 
rule.
cc -DSYSCONFDIR=\"/etc\" -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -
fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -fPIC -DNOMIXER -I/
builddir/build/BUILD/fmio-2.0.8/src -o access.o -c access.c
In file included from access.c:38:
radio_drv.h:35:20: error: sys/io.h: No such file or directory
access.c: In function 'os_iopl':
access.c:87: warning: implicit declaration of function 'iopl'
access.c: In function 'os_ioperms':
access.c:96: warning: implicit declaration of function 'ioperm'
make[1]: *** [access.o] Error 1
make[1]: Leaving directory `/builddir/build/BUILD/fmio-2.0.8/src'
...

Version-Release number of selected component (if applicable):
2.0.8-7

Comment 1 Andy Shevchenko 2006-09-08 10:19:50 UTC
So, temporary stop build for non-x86 arches.


Comment 2 Kevin Fenzi 2006-09-08 15:46:48 UTC
You should probibly add:
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=179260
as a blocker here.


Comment 3 Andy Shevchenko 2006-09-09 08:07:29 UTC
Sure. Thanks.

Comment 4 David Woodhouse 2006-09-09 08:25:34 UTC
What is this code trying to do? You can't have port I/O address from userspace
directly on most architectures, but this code is trying to do that.

If the package contains generic code which works properly through kernel device
drivers (which is what it _should_ be doing anyway), then you should build that
part on PowerPC, and just disable building the direct-io hacks. 

Comment 5 Andy Shevchenko 2006-09-09 08:35:20 UTC
This code has included the set of FM card drivers as libradio. The main 
author's idea was to get working FM card independend of kernel driver.
However, the driver set is included the v4l module for generic kernel device.


Comment 6 Andy Shevchenko 2006-09-11 08:31:00 UTC
Cite from mainstream:

Date:	Sun, 10 Sep 2006 11:11:15 +0400 (MSD)
From: "Vladimir Popov" <jumbo>
Message-Id: <4503BA93.000008.13099.ru>
To: andy.ua
Subject: Re: fmio vs. contribution and licensing

>The pam mechaism of the Fedora and clones provides the special 
>attributes for devices to console owner. Hence, /dev/radio for me (login 
>name: andy) has permissions like:
>   600 andy:root
>And user andy can operate with /dev/radio w/o root perms obviously.

You're talking about v4l. The driver was included only for a convenience.
See below.

>So, a new information I'd like to discuss. Since FE is built on i686, 
>x86_64, and ppc arches the last case isn't compatible with fmio sources.
>Additional information can be retrived by following url:
>https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=205721
>
>What could you advise here?

fmio was developed to operate fm cards when kernel doesn't have an
appropriate driver (I'm speaking about all frunixes). In the time I've
been writing it such situation was commonplace and the only hardware
available for me was i386. This explains why fmio uses direct port
access and is compatible only with i386 (and why it should keep the
setuid bit).

Thus, unless you're going to add support for other arches, you should
build fmio only for i686.


Comment 7 David Woodhouse 2006-12-28 15:26:03 UTC
(In reply to comment #6)
> Thus, unless you're going to add support for other arches, you should
> build fmio only for i686.

No, we should build it with only the driver for v4l and not the direct port I/O.
That shouldn't be hard. The X front end is still perfectly useful on other
architectures.



Comment 8 Fedora Update System 2007-11-12 23:58:26 UTC
fmio-2.0.8-10.fc7 has been pushed to the Fedora 7 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update fmio'

Comment 9 Fedora Update System 2007-11-13 00:07:18 UTC
fmio-2.0.8-10.fc8 has been pushed to the Fedora 8 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update fmio'

Comment 10 Fedora Update System 2007-11-17 05:35:16 UTC
fmio-2.0.8-10.fc7 has been pushed to the Fedora 7 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 11 Fedora Update System 2007-11-17 05:36:20 UTC
fmio-2.0.8-10.fc8 has been pushed to the Fedora 8 stable repository.  If problems still persist, please make note of it in this bug report.