Bug#834204: libsdl1.2: Nonfree file: src/video/fbcon/riva_mmio.h

2017-07-18 Thread Manuel A. Fernandez Montecelo

Hi Jonas,

2017-07-18 14:14 Jonas Smedegaard:

Package: src:libsdl1.2
Followup-For: Bug #834204

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA512

I have prepared an NMU and queued for release in 5 days.

Attached is the diff.


Thanks.  I am in the midst of a snowstorm, metaphorically speaking, so I
didn't have time (and neither I will have in the next few days) to
review this in depth, but in principle I trust your good judgement so
all fine by me, including the NMU.



I made the changes in git locally, and can push that to Alioth if
granted write access to the repository (my account is js).
Alternatively I can put my git public somewhere for you to clone if you
prefer.


If you want to become a somewhat-regular contributor / maintainer the
first option is preferrable, otherwise I think that the output of
format-path is intended for this kind of situations, and preserves
authorship and all that (?).  Whatever you prefer, really.


... and big thanks for caring and fixing this bug.


PS: (Would be super if you contact upstream about it, but it's fine if
   you don't want to get so involved.  I'll try to remember in the next
   revision of the package).


--
Manuel A. Fernandez Montecelo 



Bug#834204: libsdl1.2: Nonfree file: src/video/fbcon/riva_mmio.h

2017-07-18 Thread Jonas Smedegaard
Package: src:libsdl1.2
Followup-For: Bug #834204

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA512

Whoops - forgot to acutally attach the diff.

 - Jonas

- -- System Information:
Debian Release: buster/sid
  APT prefers buildd-unstable
  APT policy: (500, 'buildd-unstable'), (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 4.11.0-1-amd64 (SMP w/2 CPU cores)
Locale: LANG=C.UTF-8, LC_CTYPE=C.UTF-8 (charmap=UTF-8), LANGUAGE=C.UTF-8 
(charmap=UTF-8)
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)

-BEGIN PGP SIGNATURE-

iQIzBAEBCgAdFiEEn+Ppw2aRpp/1PMaELHwxRsGgASEFAllt+/EACgkQLHwxRsGg
ASGtXg//fTrFEtoLczPWhkKQ3A2YuiGqjkpgJhIvdFRcJsLa29ixrh9hraWGeN1j
FMfaYABS7aoeAd1Efpn6HqE+leT9SslCSgeromLBtmyX/blusRvLMYFipOJmhCOE
LzZHsDAUo7nE6wKH9xPbHOxwFL4ZzKBoqWFZ+SKumpVkTRijld0D0+4Z4LE5kiUZ
raerilDHCLqQrWZr9Vof/p4HyYgapYHYXZ+h9foRm48kzZuUIHQs75KtXO2PCdQn
pz28AwpAIaOMukZ9eq462Z4agDoarasHJMjDXHLxxxz2gti76iCMbKEKOJGcVj9t
TKVqMD0x2rqKJ0S3eiXfMv0Cf00yGj1y4PCA3aFfS2QdIw6OV9eBsPRDA1Gglzcu
stxB73dYYKibqLHgUgU01RsSXd8aIZcb42Y3mW1lKRImJm3XqTpMgu1Ye4jUgYVE
NHydJNt+1rZq8RyXhuUzFRFM+ow/t+ukPaRBGcJ1uHuKOHEjvMOX0xuT4W+BUA0W
FUDNUgVsPTndXDZ12VODlxCEMBpp3/vsbInMjOof1LUK0vTdQ6WrbA9eFKz33cwh
sc8++C5hJZ90emkQfMe2/0VtXpQ3uasv8WgVGmFUX1PsVOzV4Q+VHCJi3y2/02br
XE0ZqLDCV7Ei1a7PGjTchHnZsLENqivZXzhPm4G8F6sEDwMSWO0=
=tCu0
-END PGP SIGNATURE-


nmu.diff
Description: Binary data


Bug#834204: libsdl1.2: Nonfree file: src/video/fbcon/riva_mmio.h

2017-07-18 Thread Jonas Smedegaard
Package: src:libsdl1.2
Followup-For: Bug #834204

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA512

I have prepared an NMU and queued for release in 5 days.

Attached is the diff.

I made the changes in git locally, and can push that to Alioth if
granted write access to the repository (my account is js).
Alternatively I can put my git public somewhere for you to clone if you
prefer.

 - Jonas

- -- System Information:
Debian Release: buster/sid
  APT prefers buildd-unstable
  APT policy: (500, 'buildd-unstable'), (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 4.11.0-1-amd64 (SMP w/2 CPU cores)
Locale: LANG=C.UTF-8, LC_CTYPE=C.UTF-8 (charmap=UTF-8), LANGUAGE=C.UTF-8 
(charmap=UTF-8)
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)

-BEGIN PGP SIGNATURE-

iQIzBAEBCgAdFiEEn+Ppw2aRpp/1PMaELHwxRsGgASEFAllt+50ACgkQLHwxRsGg
ASHhCxAAj1GSl6n3oAmymMiX9CI1uFPZAefNs/+8chmlX0pbZKYAjvw9W2Lu35eS
eWLE9BBPOXjKsSqRnW6uM9xnaySu4zOlyYeEv/h/GZm8u4tunmr6OtCZpDQSI+Cy
DxHmt4fw6WhZ+/e3EmehKUni8QIX+h5GqZ/OCt7/MsqNMIuyvd1rhpbqGRXXtqVe
uEg/l1uHKzNdjNjUIpGCPJCumCnQRLPNDva/2A90Xam5twEV4NnnTuEn4P1m0kCm
NvkhhAVIN18xvkqQHyJRBgeuBEWaxT8OU+doSyQFvW/YVu8wFiJh39/MMcy4jnJ3
+/JzPWwa59KD7SiIoQO24P1KFXrRfekemiLqYUPHdK9WiGtd6oF02LQSVfp02Di8
TWvXS9KClIk/AverR1aTPuBXzK8cApWQ4pCcpFWrlrAGHlyfS1pe9tv0PP8nayhi
y+el3volYY2Z90m2GXWL3GDdjo76MrM1XbB2GdS37TDWXPwekC7I0W8LSuw2xPZu
N8l2MsxpRS6Zr4ybxxjTOAq/qiTp5N3f6SiiRDu5ZM1RkK6ASzLqS9VQ5tMcJOgx
S9IDenznNqsooVKpmQGUG6DYs/N4p+5Es2Ee7Ggk2UQ03iSGFhDyghXsDzb9mgIC
ozTIWQXfVNFiEWUdoqYimIVj5iGfG3QiaAS3LQaqmaPxHiq8tr8=
=Wl8e
-END PGP SIGNATURE-



Bug#834204: libsdl1.2: Nonfree file: src/video/fbcon/riva_mmio.h

2017-07-17 Thread Jonas Smedegaard
Source: libsdl1.2
Followup-For: Bug #834204

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA512

Attached is a patch from Parabola to avoid using the baguely licensed
file, to survive a repackaging with it stripped.

 - Jonas

- -- System Information:
Debian Release: buster/sid
  APT prefers buildd-unstable
  APT policy: (500, 'buildd-unstable'), (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 4.11.0-1-amd64 (SMP w/2 CPU cores)
Locale: LANG=C.UTF-8, LC_CTYPE=C.UTF-8 (charmap=UTF-8), LANGUAGE=C.UTF-8 
(charmap=UTF-8)
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)

-BEGIN PGP SIGNATURE-

iQIzBAEBCgAdFiEEn+Ppw2aRpp/1PMaELHwxRsGgASEFAlls/YYACgkQLHwxRsGg
ASHVjA//ZhhUBmIThagxO9c8uLjHsRi0a9QmWrG11FSn6nkDlUyuAURKLs3FTRCD
5D42XtSf86xfVXcnMY/EACurhWB0zWB+y1h03tIOYHSodfTnMpk0yiTv/i9TkfBL
7jYtezOpehfqV8xVyBR9lye2tqPqpVy2l+INlDmEdutV+MMZk2r7CGETcVcunt8E
LsxCJOMmvQmlCt0GN5+7gh3JHJHDEk/36P7Qaj1q/rVSEH6xNm81nIQH8DNca0cB
+CFin5WBw9NogS3Gaf9pv6RM6NawXLp/WxE94nf1+0F7Wd78nES5YrH3CycL7ssO
vZqlsgKDs2r+tEnWNtNB9g4JakUah/QHBma5gf4ksNiSrKC54oyh9Lb1fnVl0Srm
LGrALFvIglpjKpFuyRLUHbucZURac1KN6RiOe2KGAuHLgiJA70IrWWpZC1a0eF/U
1EWk7eCPr+KN5ORasf59Q1yOX36NIsGL3mzwXW4uiEcM0GCjHKXl6/RaLxTJnCNQ
13t2fWHI1JLxn/szHG79X9LFvRIqftl8M/+a+eWWdgSHBWzbUm5rcuuFyjCeoAQR
IPAeItMRON/iBUQMeb3pmxhwbEKeLJ9DDpsPml3Yq9YM3RvltEheAnt8QuO40cNI
d/x/h7O8sShPuWNbLQDHViy8RqImsaZAEu+hbv3qBBgkvBH+vhY=
=dZcH
-END PGP SIGNATURE-
Description: Avoid maybe non-DFSG file
 Avoid use of source file with vague licensing terms regarding
 modification
Origin: https://git.parabola.nu/abslibre.git/log/libre/sdl/libre.patch
Last-Update: 2017-07-17
Bug-Debian: http://bugs.debian.org/834204
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
--- a/src/video/fbcon/SDL_fbriva.c
+++ b/src/video/fbcon/SDL_fbriva.c
@@ -24,12 +24,10 @@
 #include "SDL_video.h"
 #include "../SDL_blit.h"
 #include "SDL_fbriva.h"
-#include "riva_mmio.h"
 #include "riva_regs.h"
 
 
 static int FifoEmptyCount = 0;
-static int FifoFreeCount = 0;
 
 /* Wait for vertical retrace */
 static void WaitVBL(_THIS)
@@ -41,20 +39,6 @@
while ( !(*port & 0x08) )
;
 }
-static void NV3WaitIdle(_THIS)
-{
-   RivaRop *Rop = (RivaRop *)(mapped_io + ROP_OFFSET);
-   while ( (Rop->FifoFree < FifoEmptyCount) ||
-   (*(mapped_io + PGRAPH_OFFSET + 0x06B0) & 0x01) )
-   ;
-}
-static void NV4WaitIdle(_THIS)
-{
-   RivaRop *Rop = (RivaRop *)(mapped_io + ROP_OFFSET);
-   while ( (Rop->FifoFree < FifoEmptyCount) ||
-   (*(mapped_io + PGRAPH_OFFSET + 0x0700) & 0x01) )
-   ;
-}
 
 #if 0 /* Not yet implemented? */
 /* Sets video mem colorkey and accelerated blit function */
@@ -74,7 +58,6 @@
 {
int dstX, dstY;
int dstW, dstH;
-   RivaBitmap *Bitmap = (RivaBitmap *)(mapped_io + BITMAP_OFFSET);
 
/* Don't blit to the display surface when switched away */
if ( switched_away ) {
@@ -93,13 +76,6 @@
dstX += rect->x;
dstY += rect->y;
 
-   RIVA_FIFO_FREE(Bitmap, 1);
-   Bitmap->Color1A = color;
-
-   RIVA_FIFO_FREE(Bitmap, 2);
-   Bitmap->UnclippedRectangle[0].TopLeft = (dstX << 16) | dstY; 
-   Bitmap->UnclippedRectangle[0].WidthHeight = (dstW << 16) | dstH;
-
FB_AddBusySurface(dst);
 
if ( dst == this->screen ) {
@@ -115,7 +91,6 @@
int srcX, srcY;
int dstX, dstY;
int dstW, dstH;
-   RivaScreenBlt *Blt = (RivaScreenBlt *)(mapped_io + BLT_OFFSET);
 
/* FIXME: For now, only blit to display surface */
if ( dst->pitch != SDL_VideoSurface->pitch ) {
@@ -142,11 +117,6 @@
dstX += dstrect->x;
dstY += dstrect->y;
 
-   RIVA_FIFO_FREE(Blt, 3);
-   Blt->TopLeftSrc  = (srcY << 16) | srcX;
-   Blt->TopLeftDst  = (dstY << 16) | dstX;
-   Blt->WidthHeight = (dstH  << 16) | dstW;
-
FB_AddBusySurface(src);
FB_AddBusySurface(dst);
 
@@ -185,23 +155,15 @@
 
 void FB_RivaAccel(_THIS, __u32 card)
 {
-   RivaRop *Rop = (RivaRop *)(mapped_io + ROP_OFFSET);
 
/* We have hardware accelerated surface functions */
this->CheckHWBlit = CheckHWBlit;
wait_vbl = WaitVBL;
switch (card) {
-   case FB_ACCEL_NV3:
-   wait_idle = NV3WaitIdle;
-   break;
-   case FB_ACCEL_NV4:
-   wait_idle = NV4WaitIdle;
-   break;
default:
/* Hmm... FIXME */
break;
}
-   FifoEmptyCount = Rop->FifoFree;
 
/* The Riva has an accelerated color fill */
this->info.blit_fill = 1;
--- a/src/video/fbcon/SDL_fbvideo.c
+++ b/src/video/fbcon/SDL_fbvideo.c
@@ -46,7 +46,6 @@
 #include "SDL_fbevents_c.h"
 #include "SDL_fb3dfx.h"
 #include "SDL_fbmatrox.h"
-#include "SDL_fbriva.h"
 
 /*#define FBCON_DEBUG*/
 
@@ -769,13 +768,6 @@
 #endif

Bug#834204: libsdl1.2: Nonfree file: src/video/fbcon/riva_mmio.h

2017-03-19 Thread Ivo De Decker
Control: tags -1 stretch-ignore

Hi,

On Sat, Aug 13, 2016 at 10:50:03AM +0100, Manuel A. Fernandez Montecelo wrote:
> > The file src/video/fbcon/riva_mmio.h has a nonfree license that does not
> > explicitly allow modification.
> 
> Thanks for the report.
> 
> I am copying FTP-masters to know their opinion.
> 
> This file has been present in Debian for the best part of 2 decades,
> so possibly the people who reviewed and approved this initially are
> not around anymore or, if they are, that they don't recall the details
> if they were discussed.
> 
> From my understanding, despite the brevity of the wording but given
> the context, with "using this code in individual and commercial
> software" is implicit the possibility of modification, as in "use in
> any way you wish" -- modifications might be needed due to changes in
> compiler/toolchain or to integrate in the bigger "commercial" software
> (e.g. changing names to avoid clashes).
> 
> These licenses are usually to prevent that the source code is
> leaked/accessible to the outside world, or used in commercial software
> without being paid.  Since this license prevents neither, I don't
> think that prevent modification is of any use to the copyright
> holders...
> 
>  but it's true that it doesn't explicitly allow modification or
> says anything beyond "use".
> 
> 
> > The file is from xf86-video-nv, and has
> > subsequently been relicensed under the MIT/Expat license:
> > https://cgit.freedesktop.org/xorg/driver/xf86-video-nv/tree/src/riva_hw.h
> >
> > It should be possible to use the newer version of the file.
> 
> The code is not identical, for example the "NV_" macros in the
> beginning of the old file are not present in the second.
> 
> The "struct _riva_hw_inst" is different in both versions as well (e.g.
> fields Architecture and Version present in the first file, but not in
> the second), so not API nor ABI compatible.
> 
> So it needs to be handled with some care in any case.

Based on the fact that the license for the newer version of the file is OK,
and that we shipped the old version for a long time, I think it's better to
leave it the way it is for stretch, to avoid breaking things this late in the
freeze. Tagging accordingly. This issue should be fixed after the stretch
release.

Cheers,

Ivo



Processed: Re: Bug#834204: libsdl1.2: Nonfree file: src/video/fbcon/riva_mmio.h

2017-03-19 Thread Debian Bug Tracking System
Processing control commands:

> tags -1 stretch-ignore
Bug #834204 [src:libsdl1.2] libsdl1.2: Nonfree file: src/video/fbcon/riva_mmio.h
Added tag(s) stretch-ignore.

-- 
834204: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=834204
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems



Bug#834204: libsdl1.2: Nonfree file: src/video/fbcon/riva_mmio.h

2016-08-13 Thread Manuel A. Fernandez Montecelo
Hi,

2016-08-13 3:44 GMT+01:00 Legimet :
> Source: libsdl1.2
> Version: 1.2.15+dfsg1-4
> Severity: serious
> Justification: Policy 2.1
>
> Dear Maintainer,
>
> The file src/video/fbcon/riva_mmio.h has a nonfree license that does not
> explicitly allow modification.

Thanks for the report.

I am copying FTP-masters to know their opinion.

This file has been present in Debian for the best part of 2 decades,
so possibly the people who reviewed and approved this initially are
not around anymore or, if they are, that they don't recall the details
if they were discussed.

>From my understanding, despite the brevity of the wording but given
the context, with "using this code in individual and commercial
software" is implicit the possibility of modification, as in "use in
any way you wish" -- modifications might be needed due to changes in
compiler/toolchain or to integrate in the bigger "commercial" software
(e.g. changing names to avoid clashes).

These licenses are usually to prevent that the source code is
leaked/accessible to the outside world, or used in commercial software
without being paid.  Since this license prevents neither, I don't
think that prevent modification is of any use to the copyright
holders...

 but it's true that it doesn't explicitly allow modification or
says anything beyond "use".


> The file is from xf86-video-nv, and has
> subsequently been relicensed under the MIT/Expat license:
> https://cgit.freedesktop.org/xorg/driver/xf86-video-nv/tree/src/riva_hw.h
>
> It should be possible to use the newer version of the file.

The code is not identical, for example the "NV_" macros in the
beginning of the old file are not present in the second.

The "struct _riva_hw_inst" is different in both versions as well (e.g.
fields Architecture and Version present in the first file, but not in
the second), so not API nor ABI compatible.

So it needs to be handled with some care in any case.


(BTW, it would be nice to discuss this with upstream if it needs to be
removed/updated, unfortunately I don't have much time in the next few
weeks, so if somebody beats me to it I will not complain :) .  They
should also have access to some nice legal department, being developed
by Steam now).


Cheers.
-- 
Manuel A. Fernandez Montecelo 



Bug#834204: libsdl1.2: Nonfree file: src/video/fbcon/riva_mmio.h

2016-08-12 Thread Legimet
Source: libsdl1.2
Version: 1.2.15+dfsg1-4
Severity: serious
Justification: Policy 2.1

Dear Maintainer,

The file src/video/fbcon/riva_mmio.h has a nonfree license that does not
explicitly allow modification. The file is from xf86-video-nv, and has
subsequently been relicensed under the MIT/Expat license:
https://cgit.freedesktop.org/xorg/driver/xf86-video-nv/tree/src/riva_hw.h

It should be possible to use the newer version of the file.

Thanks,
Legimet

-- System Information:
Debian Release: 8.5
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.6.0-0.bpo.1-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)