rpms/psb-kmod/F-13 psb-kernel-source-4.41.1-2.6.32.patch, NONE, 1.1 psb-kernel-source-4.41.1-agp_memory.patch, NONE, 1.1 psb-kernel-source-4.41.1-drmpsb.patch, NONE, 1.1 psb-kernel-source-4.41.1-i2c-intelfb.patch, NONE, 1.1 psb-kmd-4.34-current_euid.patch, NONE, 1.1 psb-kmod-4.41.1_busid.patch, NONE, 1.1 psb-kmod-4.41.1_irqreturn.patch, NONE, 1.1 psb-kmod.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2

Adam Williamson adamwill at rpmfusion.org
Thu Jul 15 22:09:08 CEST 2010


Author: adamwill

Update of /cvs/nonfree/rpms/psb-kmod/F-13
In directory se02.es.rpmfusion.net:/tmp/cvs-serv21952/F-13

Modified Files:
	.cvsignore sources 
Added Files:
	psb-kernel-source-4.41.1-2.6.32.patch 
	psb-kernel-source-4.41.1-agp_memory.patch 
	psb-kernel-source-4.41.1-drmpsb.patch 
	psb-kernel-source-4.41.1-i2c-intelfb.patch 
	psb-kmd-4.34-current_euid.patch psb-kmod-4.41.1_busid.patch 
	psb-kmod-4.41.1_irqreturn.patch psb-kmod.spec 
Log Message:
- initial import to F-13 branch


psb-kernel-source-4.41.1-2.6.32.patch:
 drm_agpsupport.c |    2 +-
 drm_edid.c       |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

--- NEW FILE psb-kernel-source-4.41.1-2.6.32.patch ---
psb: Fix compilation with kernel 2.6.32

This patch made from the Gentoo ebuild written by Zac Medico <zmedico at gentoo.org>,
to fix compilation of the psb module with kernel 2.6.32

It should be safe to be used with older version of the kernel. It fixes two changes:
 * In commit 6a12235c7d2d75c7d94b9afcaaecd422ff845ce0 phys_to_gart was removed
   since it is a 1:1 mapping on all platforms.
 * The acpi PREFIX constant is gone.

---
diff -urP psb-4.41.1-4mdv2010.0.orig/drm_agpsupport.c psb-4.41.1-4mdv2010.0.fix2632/drm_agpsupport.c
--- psb-4.41.1-4mdv2010.0.orig/drm_agpsupport.c	2009-10-08 12:09:11.000000000 +0200
+++ psb-4.41.1-4mdv2010.0.fix2632/drm_agpsupport.c	2009-12-05 02:46:28.000421027 +0100
@@ -524,7 +524,7 @@
 	DRM_DEBUG("Current page count is %ld\n", (long) mem->page_count);
 	mem->page_count = 0;
 	for (cur_page = pages; cur_page < last_page; ++cur_page)
-		mem->pages[mem->page_count++] = phys_to_gart(page_to_phys(*cur_page));
+		mem->pages[mem->page_count++] = page_to_phys(*cur_page);
 	agp_be->mem = mem;
 	return 0;
 }
diff -urP psb-4.41.1-4mdv2010.0.orig/drm_edid.c psb-4.41.1-4mdv2010.0.fix2632/drm_edid.c
--- psb-4.41.1-4mdv2010.0.orig/drm_edid.c	2009-10-08 12:09:11.000000000 +0200
+++ psb-4.41.1-4mdv2010.0.fix2632/drm_edid.c	2009-12-05 02:46:38.155168734 +0100
@@ -39,7 +39,7 @@
 	if (obj && obj->type == ACPI_TYPE_BUFFER)
 		memcpy(edid, obj->buffer.pointer, obj->buffer.length);
 	else {
-		printk(KERN_ERR PREFIX "Invalid _DDC data\n");
+		printk(KERN_ERR "ACPI: " "Invalid _DDC data\n");
 		status = -EFAULT;
 		kfree(obj);
 	}

psb-kernel-source-4.41.1-agp_memory.patch:
 drm_agpsupport.c |    2 +-
 drm_memory.c     |    2 +-
 drm_vm.c         |    4 ++--
 3 files changed, 4 insertions(+), 4 deletions(-)

--- NEW FILE psb-kernel-source-4.41.1-agp_memory.patch ---
diff -ru psb-kernel-source-4.41.1/drm_agpsupport.c psb-kernel-source-4.41.2/drm_agpsupport.c
--- psb-kernel-source-4.41.1/drm_agpsupport.c	2009-04-16 05:25:01.000000000 +0200
+++ psb-kernel-source-4.41.2/drm_agpsupport.c	2009-08-11 20:18:30.000000000 +0200
@@ -524,7 +524,7 @@
 	DRM_DEBUG("Current page count is %ld\n", (long) mem->page_count);
 	mem->page_count = 0;
 	for (cur_page = pages; cur_page < last_page; ++cur_page)
-		mem->memory[mem->page_count++] = phys_to_gart(page_to_phys(*cur_page));
+		mem->pages[mem->page_count++] = phys_to_gart(page_to_phys(*cur_page));
 	agp_be->mem = mem;
 	return 0;
 }
diff -ru psb-kernel-source-4.41.1/drm_memory.c psb-kernel-source-4.41.2/drm_memory.c
--- psb-kernel-source-4.41.1/drm_memory.c	2009-04-16 05:25:01.000000000 +0200
+++ psb-kernel-source-4.41.2/drm_memory.c	2009-08-11 20:18:30.000000000 +0200
@@ -264,7 +264,7 @@
 		return NULL;
 
 	phys_addr_map =
-	    agpmem->memory->memory + (offset - agpmem->bound) / PAGE_SIZE;
+	    agpmem->memory->pages + (offset - agpmem->bound) / PAGE_SIZE;
 	for (i = 0; i < num_pages; ++i)
 		page_map[i] = pfn_to_page(phys_addr_map[i] >> PAGE_SHIFT);
 	addr = vmap(page_map, num_pages, VM_IOREMAP, PAGE_AGP);
diff -ru psb-kernel-source-4.41.1/drm_vm.c psb-kernel-source-4.41.2/drm_vm.c
--- psb-kernel-source-4.41.1/drm_vm.c	2009-04-16 05:25:01.000000000 +0200
+++ psb-kernel-source-4.41.2/drm_vm.c	2009-08-11 20:18:30.000000000 +0200
@@ -145,13 +145,13 @@
 		 * Get the page, inc the use count, and return it
 		 */
 		offset = (baddr - agpmem->bound) >> PAGE_SHIFT;
-		page = virt_to_page(__va(agpmem->memory->memory[offset]));
+		page = virt_to_page(__va(agpmem->memory->pages[offset]));
 		get_page(page);
 		vmf->page = page;
 
 		DRM_DEBUG
 		    ("baddr = 0x%lx page = 0x%p, offset = 0x%lx, count=%d\n",
-		     baddr, __va(agpmem->memory->memory[offset]), offset,
+		     baddr, __va(agpmem->memory->pages[offset]), offset,
 		     page_count(page));
 		return 0;
 	}


psb-kernel-source-4.41.1-drmpsb.patch:
 Makefile.kernel |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

--- NEW FILE psb-kernel-source-4.41.1-drmpsb.patch ---
diff -p -up psb-kernel-source-4.41.1/Makefile.kernel.drmpsb psb-kernel-source-4.41.1/Makefile.kernel
--- psb-kernel-source-4.41.1/Makefile.kernel.drmpsb	2009-04-16 05:25:02.000000000 +0200
+++ psb-kernel-source-4.41.1/Makefile.kernel	2009-09-23 11:56:26.000000000 +0200
@@ -7,7 +7,7 @@
 # $XFree86: xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/Makefile.kernel,v 1.18 2003/08/16 17:59:17 dawes Exp $
 #
 
-drm-objs    := drm_auth.o drm_bufs.o drm_context.o drm_dma.o drm_drawable.o \
+drm-psb-objs    := drm_auth.o drm_bufs.o drm_context.o drm_dma.o drm_drawable.o \
 		drm_drv.o drm_fops.o drm_ioctl.o drm_irq.o \
 		drm_lock.o drm_memory.o drm_proc.o drm_stub.o drm_vm.o \
 		drm_sysfs.o drm_pci.o drm_agpsupport.o drm_scatter.o \
@@ -49,7 +49,7 @@ xgi-objs    := xgi_cmdlist.o xgi_drv.o x
 		xgi_fence.o
 
 ifeq ($(CONFIG_COMPAT),y)
-drm-objs    += drm_ioc32.o
+drm-psb-objs    += drm_ioc32.o
 radeon-objs += radeon_ioc32.o
 mga-objs    += mga_ioc32.o
 r128-objs   += r128_ioc32.o
@@ -58,7 +58,7 @@ nouveau-objs += nouveau_ioc32.o
 xgi-objs    += xgi_ioc32.o
 endif
 
-obj-m			+= drm.o
+obj-m			+= drm-psb.o
 obj-$(CONFIG_DRM_TDFX)	+= tdfx.o
 obj-$(CONFIG_DRM_R128)	+= r128.o
 obj-$(CONFIG_DRM_RADEON)+= radeon.o


psb-kernel-source-4.41.1-i2c-intelfb.patch:
 psb_i2c.c |    2 ++
 1 file changed, 2 insertions(+)

--- NEW FILE psb-kernel-source-4.41.1-i2c-intelfb.patch ---
diff -ru psb-kernel-source-4.41.1/psb_i2c.c psb-kernel-source-4.41.2/psb_i2c.c
--- psb-kernel-source-4.41.1/psb_i2c.c  2009-04-16 05:25:01.000000000 +0200
+++ psb-kernel-source-4.41.2/psb_i2c.c  2009-08-11 20:18:30.000000000 +0200
@@ -36,6 +36,8 @@
 #include "intel_drv.h"
 #include "psb_drv.h"

+#define I2C_HW_B_INTELFB 0x010021; /* intel framebuffer driver */
+
 /*
  * Intel GPIO access functions
  */


psb-kmd-4.34-current_euid.patch:
 drm_fops.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- NEW FILE psb-kmd-4.34-current_euid.patch ---
diff -p -up build/drm_fops.c.current_euid build/drm_fops.c
--- build/drm_fops.c.current_euid	2009-05-31 03:22:18.000000000 -0400
+++ build/drm_fops.c	2009-05-31 03:32:00.000000000 -0400
@@ -252,7 +252,7 @@ static int drm_open_helper(struct inode 
 	memset(priv, 0, sizeof(*priv));
 	filp->private_data = priv;
 	priv->filp = filp;
-	priv->uid = current->euid;
+	priv->uid = current_euid();
 	priv->pid = current->pid;
 	priv->minor = minor;
 	priv->head = drm_heads[minor];


psb-kmod-4.41.1_busid.patch:
 drm_sysfs.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- NEW FILE psb-kmod-4.41.1_busid.patch ---
--- psb-kernel-source-4.41.1/drm_sysfs.c	2009-04-15 20:25:01.000000000 -0700
+++ psb-kernel-source-4.41.1/drm_sysfs.c.new	2009-08-17 22:40:44.635097318 -0700
@@ -168,7 +168,7 @@
 	 * yet...
 	 */
 	/* dev->dev.devt = head->device; */
-	snprintf(dev->dev.bus_id, BUS_ID_SIZE, "card%d", head->minor);
+	dev_set_name(&dev->dev, "card%d", head->minor);
 
 	err = device_register(&dev->dev);
 	if (err) {

psb-kmod-4.41.1_irqreturn.patch:
 drm_os_linux.h |    6 ------
 1 file changed, 6 deletions(-)

--- NEW FILE psb-kmod-4.41.1_irqreturn.patch ---
--- psb-kernel-source-4.41.1/drm_os_linux.h	2009-04-15 20:25:01.000000000 -0700
+++ psb-kernel-source-4.41.1/drm_os_linux.h.new	2009-08-24 17:08:44.896703277 -0700
@@ -49,12 +49,6 @@
 
 /** IRQ handler arguments and return type and values */
 #define DRM_IRQ_ARGS		int irq, void *arg
-/** backwards compatibility with old irq return values */
-#ifndef IRQ_HANDLED
-typedef void irqreturn_t;
-#define IRQ_HANDLED		/* nothing */
-#define IRQ_NONE		/* nothing */
-#endif
 
 /** AGP types */
 #if __OS_HAS_AGP


--- NEW FILE psb-kmod.spec ---
# buildforkernels macro hint: when you build a new version or a new release
# that contains bugfixes or other improvements then you must disable the
# "buildforkernels newest" macro for just that build; immediately after
# queuing that build enable the macro again for subsequent builds; that way
# a new akmod package will only get build when a new one is actually needed
%define buildforkernels current

Name:		psb-kmod
Version:	4.41.1
Release:	11%{?dist}
Summary:	Kernel module for Poulsbo graphics chipsets

Group:		System Environment/Kernel
License:	GPLv2+
URL:		http://ppa.launchpad.net/ubuntu-mobile/ubuntu/pool/main/p/psb-kernel-source/
Source0:	http://ppa.launchpad.net/ubuntu-mobile/ubuntu/pool/main/p/psb-kernel-source/psb-kernel-source_%{version}.orig.tar.gz

# upstream status for all patches: upstream? heh. good joke.

# kernel 2.6.29 build patch, from mandriva
Patch0:		psb-kmd-4.34-current_euid.patch
# kernel 2.6.30 build patch, by me
Patch1:		psb-kmod-4.41.1_irqreturn.patch
# kernel 2.6.30 build patch, by me (mandriva has the same patch
# independently arrived at, they call it dev_set_name.patch)
Patch2:		psb-kmod-4.41.1_busid.patch
# kernel 2.6.30 build patch, from ubuntu via mandriva
Patch3:		psb-kernel-source-4.41.1-agp_memory.patch
# rename drm.ko to drm-psb.ko so we don't get dependency ickiness due
# to competition with the 'real' drm.ko (from mandriva)
Patch4:		psb-kernel-source-4.41.1-drmpsb.patch
# define intel framebuffer driver (fixes a build problem)
# (from mandriva)
Patch5:		psb-kernel-source-4.41.1-i2c-intelfb.patch
# Fix build for 2.6.32 (from Gentoo via Mandriva)
Patch6:		psb-kernel-source-4.41.1-2.6.32.patch
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
ExclusiveArch:	i586 i686

# get the needed BuildRequires (in parts depending on what we build for)
%{!?kernels:BuildRequires: buildsys-build-rpmfusion-kerneldevpkgs-%{?buildforkernels:%{buildforkernels}}%{!?buildforkernels:current}-%{_target_cpu} }
# kmodtool does its magic here
%{expand:%(kmodtool --target %{_target_cpu} --repo rpmfusion --kmodname %{name} %{?buildforkernels:--%{buildforkernels}} %{?kernels:--for-kernels "%{?kernels}"} 2>/dev/null) }

%description
%{summary}.


%prep
%{?kmodtool_check}
kmodtool  --target %{_target_cpu} --repo rpmfusion --kmodname %{name} %{?buildforkernels:--%{buildforkernels}} %{?kernels:--for-kernels "%{?kernels}"} 2>/dev/null


%setup -q -c

for kernel_version  in %{?kernel_versions} ; do
    cp -a psb-kernel-source-%{version} _kmod_build_${kernel_version%%___*}
 pushd _kmod_build_${kernel_version%%___*}
  if [[ $kernel_version > "2.6.28.99" ]]; then
%patch0 -p1 -b .build
%patch5 -p1 -b .intelfb
  fi
  if [[ $kernel_version > "2.6.29.99" ]]; then
%patch1 -p1 -b .irqreturn
%patch2 -p1 -b .busid
  fi
  if [[ $kernel_version > "2.6.30.99" ]]; then
%patch3 -p1 -b .agp
  fi
  if [[ $kernel_version > "2.6.31.99" ]]; then
%patch6 -p1 -b .build2632
  fi
%patch4 -p1 -b .drmpsb
 popd
done


%build
for kv in %{?kernel_versions} ; do
    d=$PWD/_kmod_build_${kv%%___*}
    pushd $d
    make LINUXDIR="${kv##*___}" DRM_MODULES=psb
    popd
done


%install
rm -rf $RPM_BUILD_ROOT
for kv in %{?kernel_versions} ; do
    d=$RPM_BUILD_ROOT%{kmodinstdir_prefix}/${kv%%___*}/%{kmodinstdir_postfix}
    install -dm 755 $d
    install -pm 755 _kmod_build_${kv%%___*}/psb.ko $d
    install -pm 755 _kmod_build_${kv%%___*}/drm-psb.ko $d
done

%{?akmod_install}


%clean
rm -rf $RPM_BUILD_ROOT


%changelog
* Fri May 21 2010 Adam Williamson <adamwill AT shaw DOT ca> - 4.41.1-11
- add 2.6.32.patch (from Gentoo via Mandriva, fixes build on 2.6.32)

* Thu Feb 11 2010 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.10
- rebuild for new kernel

* Mon Feb 08 2010 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.9
- rebuild for new kernel

* Thu Feb 04 2010 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.8
- rebuild for new kernel

* Fri Jan 22 2010 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.7
- rebuild for new kernel

* Sat Dec 26 2009 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.6
- rebuild for new kernel

* Sun Dec 06 2009 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.5
- rebuild for new kernel

* Sun Nov 22 2009 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.4
- rebuild for new kernels

* Thu Nov 05 2009 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.3
- rebuild for new kernels

* Tue Oct 20 2009 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.2
- rebuild for new kernels

* Wed Sep 30 2009 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info> - 4.41.1-10.1
- rebuild for new kernels

* Thu Sep 24 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-10
- add several patches from mandriva:
	+ replace build.patch with mdv's current_euid.patch (cleaner)
	+ replace agpmem.patch with mdv's agp_memory.patch (cleaner)
	+ add drmpsb.patch (builds drm module as drm-psb.ko)
	+ add intelfb.patch (cleaner fix for a build issue which
	  used to be fixed in my old build.patch)

* Fri Aug 28 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-9
- initial cut at a 2.6.31 patch (taken from corresponding changes in
  upstream files)

* Mon Aug 24 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-8
- try just 'i586 i686' for exclusivearch

* Mon Aug 24 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-7
- drop exclusivearch for now, it is being annoying
- improve irqreturn.patch, should prevent spurious interrupt problem
  (thanks to Konstantin Kletschke)

* Thu Aug 20 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-6
- exclusivearch ix86 (there's no 64-bit poulsbo hardware)
- and drop libdrm-poulsbo BR (doesn't seem necessary)

* Wed Aug 19 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-5
- bump revision to make sure correct patches included

* Mon Aug 17 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-4
- try and fix for 2.6.30

* Tue Aug 11 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-3
- rebuild with changed libdrm-poulsbo just to make sure it works

* Mon Aug 10 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-2
- use AkmodsBuildRequires (so the akmod requires work right)

* Mon Aug 10 2009 Adam Williamson <adamwill AT shaw.ca> - 4.41.1-1
- New version

* Wed May 13 2009 Adam Williamson <adamwill AT shaw.ca> - 4.40-1
- Initial package



Index: .cvsignore
===================================================================
RCS file: /cvs/nonfree/rpms/psb-kmod/F-13/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore	24 Sep 2009 15:23:26 -0000	1.1
+++ .cvsignore	15 Jul 2010 20:09:07 -0000	1.2
@@ -0,0 +1 @@
+psb-kernel-source_4.41.1.orig.tar.gz


Index: sources
===================================================================
RCS file: /cvs/nonfree/rpms/psb-kmod/F-13/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources	24 Sep 2009 15:23:26 -0000	1.1
+++ sources	15 Jul 2010 20:09:07 -0000	1.2
@@ -0,0 +1 @@
+5ca47555507dec0318a6ed4128f73146  psb-kernel-source_4.41.1.orig.tar.gz



More information about the rpmfusion-commits mailing list