CURRENT r255426: x11/nvidia-driver: nvidia_subr.c:835:46: error: too few arguments to function call, expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

CURRENT r255426: x11/nvidia-driver: nvidia_subr.c:835:46: error: too few arguments to function call, expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);

O. Hartmann-4
x11/nvidia-driver (as well as emulators/virtualbox-ose-kmod) do not
compile on  FreeBSD 10.0-CURRENT #0 r255426: Mon Sep  9 21:35:43 CEST
2013 amd64.

The error is:

x11/nvidia-driver:

--- nvidia_subr.o ---
nvidia_subr.c:835:46: error: too few arguments to function call,
expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);
                                             ^
@/vm/vm_map.h:368:1: note: 'vm_map_find' declared here
int vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t *,
vm_size_t, ^
1 error generated.
*** [nvidia_subr.o] Error code 1


emulators/virtualbox-ose-kmod:

[...]
 /usr/ports/emulators/virtualbox-ose-kmod/work/VirtualBox-4.2.18/out/freebsd.amd64/release/bin/src/vboxdrv/r0drv/freebsd/alloc-r0drv-freebsd.c:83:76:
error: too few arguments to function call, expected 10, have 9
cbAllocated, TRUE, VM_PROT_ALL, VM_PROT_ALL, 0); ^ @/vm/vm_map.h:368:1:
note: 'vm_map_find' declared here int vm_map_find(vm_map_t,
vm_object_t, vm_ooffset_t, vm_offset_t *, vm_size_t,

signature.asc (499 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: CURRENT r255426: x11/nvidia-driver: nvidia_subr.c:835:46: error: too few arguments to function call, expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);

Ivan Klymenko
В Mon, 9 Sep 2013 22:37:48 +0200
"O. Hartmann" <[hidden email]> пишет:

> x11/nvidia-driver (as well as emulators/virtualbox-ose-kmod) do not
> compile on  FreeBSD 10.0-CURRENT #0 r255426: Mon Sep  9 21:35:43 CEST
> 2013 amd64.
>
> The error is:
>
> x11/nvidia-driver:
>
> --- nvidia_subr.o ---
> nvidia_subr.c:835:46: error: too few arguments to function call,
> expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);
>                                              ^
> @/vm/vm_map.h:368:1: note: 'vm_map_find' declared here
> int vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t *,
> vm_size_t, ^
> 1 error generated.
> *** [nvidia_subr.o] Error code 1
>
>
> emulators/virtualbox-ose-kmod:
>
> [...]
>  /usr/ports/emulators/virtualbox-ose-kmod/work/VirtualBox-4.2.18/out/freebsd.amd64/release/bin/src/vboxdrv/r0drv/freebsd/alloc-r0drv-freebsd.c:83:76:
> error: too few arguments to function call, expected 10, have 9
> cbAllocated, TRUE, VM_PROT_ALL, VM_PROT_ALL, 0); ^
> @/vm/vm_map.h:368:1: note: 'vm_map_find' declared here int
> vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t *,
> vm_size_t,

Try the following changes:
        int rc = vm_map_find(kernel_map, pVmObject, 0, &Addr,
---                          cbAllocated, TRUE, VM_PROT_ALL, VM_PROT_ALL, 0);
+++                          cbAllocated, 0, VMFS_OPTIMAL_SPACE, VM_PROT_ALL, VM_PROT_ALL, 0);

for Nvidia driver need to make similar changes...
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: CURRENT r255426: x11/nvidia-driver: nvidia_subr.c:835:46: error: too few arguments to function call, expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);

O. Hartmann-4
On Tue, 10 Sep 2013 00:02:37 +0300
Ivan Klymenko <[hidden email]> wrote:

> В Mon, 9 Sep 2013 22:37:48 +0200
> "O. Hartmann" <[hidden email]> пишет:
>
> > x11/nvidia-driver (as well as emulators/virtualbox-ose-kmod) do not
> > compile on  FreeBSD 10.0-CURRENT #0 r255426: Mon Sep  9 21:35:43
> > CEST 2013 amd64.
> >
> > The error is:
> >
> > x11/nvidia-driver:
> >
> > --- nvidia_subr.o ---
> > nvidia_subr.c:835:46: error: too few arguments to function call,
> > expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);
> >                                              ^
> > @/vm/vm_map.h:368:1: note: 'vm_map_find' declared here
> > int vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t *,
> > vm_size_t, ^
> > 1 error generated.
> > *** [nvidia_subr.o] Error code 1
> >
> >
> > emulators/virtualbox-ose-kmod:
> >
> > [...]
> >  /usr/ports/emulators/virtualbox-ose-kmod/work/VirtualBox-4.2.18/out/freebsd.amd64/release/bin/src/vboxdrv/r0drv/freebsd/alloc-r0drv-freebsd.c:83:76:
> > error: too few arguments to function call, expected 10, have 9
> > cbAllocated, TRUE, VM_PROT_ALL, VM_PROT_ALL, 0); ^
> > @/vm/vm_map.h:368:1: note: 'vm_map_find' declared here int
> > vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t *,
> > vm_size_t,
>
> Try the following changes:
>         int rc = vm_map_find(kernel_map, pVmObject, 0, &Addr,
> ---                          cbAllocated, TRUE, VM_PROT_ALL,
> VM_PROT_ALL, 0); +++                          cbAllocated, 0,
> VMFS_OPTIMAL_SPACE, VM_PROT_ALL, VM_PROT_ALL, 0);
>
> for Nvidia driver need to make similar changes...
> _______________________________________________
> [hidden email] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-current
> To unsubscribe, send any mail to
> "[hidden email]"
The man page of vm_map_find() says the last parameter is of int, named
int cow. On the hurry, I didn't find any explanation of that parameter.
Setting it to "0" (zero) also in the nvidia_subr.c makes the driver
compile again.

But simply filling in a int zero is a bit strange without knowing what
to do, isn't it?

Thanks anyway,

Oliver

signature.asc (499 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: CURRENT r255426: x11/nvidia-driver: nvidia_subr.c:835:46: error: too few arguments to function call, expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);

Ivan Klymenko
В Mon, 9 Sep 2013 23:17:13 +0200
"O. Hartmann" <[hidden email]> пишет:

> On Tue, 10 Sep 2013 00:02:37 +0300
> Ivan Klymenko <[hidden email]> wrote:
>
> > В Mon, 9 Sep 2013 22:37:48 +0200
> > "O. Hartmann" <[hidden email]> пишет:
> > >  /usr/ports/emulators/virtualbox-ose-kmod/work/VirtualBox-4.2.18/out/freebsd.amd64/release/bin/src/vboxdrv/r0drv/freebsd/alloc-r0drv-freebsd.c:83:76:
> > > error: too few arguments to function call, expected 10, have 9
> > > cbAllocated, TRUE, VM_PROT_ALL, VM_PROT_ALL, 0); ^
> > > @/vm/vm_map.h:368:1: note: 'vm_map_find' declared here int
> > > vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t *,
> > > vm_size_t,
> >
> > Try the following changes:
> >         int rc = vm_map_find(kernel_map, pVmObject, 0, &Addr,
> > ---                          cbAllocated, TRUE, VM_PROT_ALL,
> > VM_PROT_ALL, 0); +++                          cbAllocated, 0,
> > VMFS_OPTIMAL_SPACE, VM_PROT_ALL, VM_PROT_ALL, 0);
> >
> > for Nvidia driver need to make similar changes...
> The man page of vm_map_find() says the last parameter is of int, named
> int cow. On the hurry, I didn't find any explanation of that
> parameter. Setting it to "0" (zero) also in the nvidia_subr.c makes
> the driver compile again.
>
> But simply filling in a int zero is a bit strange without knowing what
> to do, isn't it?
>
> Thanks anyway,
>
> Oliver

This commit you to find an appropriate example ...
http://docs.freebsd.org/cgi/getmsg.cgi?fetch=291456+0+current/svn-src-head
And in this case, the driver Nvidia really need to specify 0 in place
of the sixth argument ...
but I'm not sure at 100% :)
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: CURRENT r255426: x11/nvidia-driver: nvidia_subr.c:835:46: error: too few arguments to function call, expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);

O. Hartmann-4
On Tue, 10 Sep 2013 00:24:05 +0300
Ivan Klymenko <[hidden email]> wrote:

> В Mon, 9 Sep 2013 23:17:13 +0200
> "O. Hartmann" <[hidden email]> пишет:
>
> > On Tue, 10 Sep 2013 00:02:37 +0300
> > Ivan Klymenko <[hidden email]> wrote:
> >
> > > В Mon, 9 Sep 2013 22:37:48 +0200
> > > "O. Hartmann" <[hidden email]> пишет:
> > > >  /usr/ports/emulators/virtualbox-ose-kmod/work/VirtualBox-4.2.18/out/freebsd.amd64/release/bin/src/vboxdrv/r0drv/freebsd/alloc-r0drv-freebsd.c:83:76:
> > > > error: too few arguments to function call, expected 10, have 9
> > > > cbAllocated, TRUE, VM_PROT_ALL, VM_PROT_ALL, 0); ^
> > > > @/vm/vm_map.h:368:1: note: 'vm_map_find' declared here int
> > > > vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t *,
> > > > vm_size_t,
> > >
> > > Try the following changes:
> > >         int rc = vm_map_find(kernel_map, pVmObject, 0, &Addr,
> > > ---                          cbAllocated, TRUE, VM_PROT_ALL,
> > > VM_PROT_ALL, 0); +++                          cbAllocated, 0,
> > > VMFS_OPTIMAL_SPACE, VM_PROT_ALL, VM_PROT_ALL, 0);
> > >
> > > for Nvidia driver need to make similar changes...
> > The man page of vm_map_find() says the last parameter is of int,
> > named int cow. On the hurry, I didn't find any explanation of that
> > parameter. Setting it to "0" (zero) also in the nvidia_subr.c makes
> > the driver compile again.
> >
> > But simply filling in a int zero is a bit strange without knowing
> > what to do, isn't it?
> >
> > Thanks anyway,
> >
> > Oliver
>
> This commit you to find an appropriate example ...
> http://docs.freebsd.org/cgi/getmsg.cgi?fetch=291456+0+current/svn-src-head
> And in this case, the driver Nvidia really need to specify 0 in place
> of the sixth argument ...
> but I'm not sure at 100% :)
I have a patch attached for the x11/nvidia-driver Makefile. It doesn't
work and I loose hairs due to not knowing why.

When issuing the following command sequence on the console:

cd /usr/ports/x11/nvidia-driver
make clean extract
sed -i -e '/(VM_PROT_READ | VM_PROT_WRITE), 0);$/s/0);$/0, 0);/g' \
work/NVIDIA-FreeBSD-x86_64-325.15/src/nvidia_subr.c


and check then line 835 (the corrupt one) in file
work/NVIDIA-FreeBSD-x86_64-325.15/src/nvidia_subr.c,

I see this BEFORE:

    status = vm_map_find(kernel_map, at->object, (i * PAGE_SIZE),
            &virtual_address, size, VMFS_ANY_SPACE,
            (VM_PROT_READ | VM_PROT_WRITE),
===(835)>>            (VM_PROT_READ | VM_PROT_WRITE), 0);


and I see this AFTER the sed'ed replacement:

    status = vm_map_find(kernel_map, at->object, (i * PAGE_SIZE),
            &virtual_address, size, VMFS_ANY_SPACE,
            (VM_PROT_READ | VM_PROT_WRITE),
===(835)>>            (VM_PROT_READ | VM_PROT_WRITE), 0, 0);

BUT: Using the patch (see attached, please apply to
x11/nvidia-driver/Makefile) gives me an error in x11/nvidia-driver:

make clean patch

===>  Cleaning for nvidia-driver-325.15
===>  License NVIDIA accepted by the user
===>  Found saved configuration for nvidia-driver-325.08_1
===>   nvidia-driver-325.15 depends on file: /usr/local/sbin/pkg - found
===> Fetching all distfiles required by nvidia-driver-325.15 for
building
===>  Extracting for nvidia-driver-325.15
=> SHA256 Checksum OK for NVIDIA-FreeBSD-x86_64-325.15.tar.gz.
===>  Patching for nvidia-driver-325.15
sed: 1: "/(VM_PROT_READ | VM_PRO ...": invalid command code 0
*** Error code 1

The Shell/make should be able to substitute within a single-quotet
command to sed, but the error message reports differently.

Do not be confused about the driver revision I use. I tried the
official one (319.XX) as well and it is not working the very same way
and the patch won't either.

Oliver

nvidia-driver.patch (553 bytes) Download Attachment
signature.asc (499 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: CURRENT r255426: x11/nvidia-driver: nvidia_subr.c:835:46: error: too few arguments to function call, expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);

Ian Lepore-3
On Tue, 2013-09-10 at 00:42 +0200, O. Hartmann wrote:

> On Tue, 10 Sep 2013 00:24:05 +0300
> Ivan Klymenko <[hidden email]> wrote:
>
> > В Mon, 9 Sep 2013 23:17:13 +0200
> > "O. Hartmann" <[hidden email]> пишет:
> >
> > > On Tue, 10 Sep 2013 00:02:37 +0300
> > > Ivan Klymenko <[hidden email]> wrote:
> > >
> > > > В Mon, 9 Sep 2013 22:37:48 +0200
> > > > "O. Hartmann" <[hidden email]> пишет:
> > > > >  /usr/ports/emulators/virtualbox-ose-kmod/work/VirtualBox-4.2.18/out/freebsd.amd64/release/bin/src/vboxdrv/r0drv/freebsd/alloc-r0drv-freebsd.c:83:76:
> > > > > error: too few arguments to function call, expected 10, have 9
> > > > > cbAllocated, TRUE, VM_PROT_ALL, VM_PROT_ALL, 0); ^
> > > > > @/vm/vm_map.h:368:1: note: 'vm_map_find' declared here int
> > > > > vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t *,
> > > > > vm_size_t,
> > > >
> > > > Try the following changes:
> > > >         int rc = vm_map_find(kernel_map, pVmObject, 0, &Addr,
> > > > ---                          cbAllocated, TRUE, VM_PROT_ALL,
> > > > VM_PROT_ALL, 0); +++                          cbAllocated, 0,
> > > > VMFS_OPTIMAL_SPACE, VM_PROT_ALL, VM_PROT_ALL, 0);
> > > >
> > > > for Nvidia driver need to make similar changes...
> > > The man page of vm_map_find() says the last parameter is of int,
> > > named int cow. On the hurry, I didn't find any explanation of that
> > > parameter. Setting it to "0" (zero) also in the nvidia_subr.c makes
> > > the driver compile again.
> > >
> > > But simply filling in a int zero is a bit strange without knowing
> > > what to do, isn't it?
> > >
> > > Thanks anyway,
> > >
> > > Oliver
> >
> > This commit you to find an appropriate example ...
> > http://docs.freebsd.org/cgi/getmsg.cgi?fetch=291456+0+current/svn-src-head
> > And in this case, the driver Nvidia really need to specify 0 in place
> > of the sixth argument ...
> > but I'm not sure at 100% :)
>
> I have a patch attached for the x11/nvidia-driver Makefile. It doesn't
> work and I loose hairs due to not knowing why.
>
> When issuing the following command sequence on the console:
>
> cd /usr/ports/x11/nvidia-driver
> make clean extract
> sed -i -e '/(VM_PROT_READ | VM_PROT_WRITE), 0);$/s/0);$/0, 0);/g' \
> work/NVIDIA-FreeBSD-x86_64-325.15/src/nvidia_subr.c
>
>
> and check then line 835 (the corrupt one) in file
> work/NVIDIA-FreeBSD-x86_64-325.15/src/nvidia_subr.c,
>
> I see this BEFORE:
>
>     status = vm_map_find(kernel_map, at->object, (i * PAGE_SIZE),
>             &virtual_address, size, VMFS_ANY_SPACE,
>             (VM_PROT_READ | VM_PROT_WRITE),
> ===(835)>>            (VM_PROT_READ | VM_PROT_WRITE), 0);
>
>
> and I see this AFTER the sed'ed replacement:
>
>     status = vm_map_find(kernel_map, at->object, (i * PAGE_SIZE),
>             &virtual_address, size, VMFS_ANY_SPACE,
>             (VM_PROT_READ | VM_PROT_WRITE),
> ===(835)>>            (VM_PROT_READ | VM_PROT_WRITE), 0, 0);
>
> BUT: Using the patch (see attached, please apply to
> x11/nvidia-driver/Makefile) gives me an error in x11/nvidia-driver:
>
> make clean patch
>
> ===>  Cleaning for nvidia-driver-325.15
> ===>  License NVIDIA accepted by the user
> ===>  Found saved configuration for nvidia-driver-325.08_1
> ===>   nvidia-driver-325.15 depends on file: /usr/local/sbin/pkg - found
> ===> Fetching all distfiles required by nvidia-driver-325.15 for
> building
> ===>  Extracting for nvidia-driver-325.15
> => SHA256 Checksum OK for NVIDIA-FreeBSD-x86_64-325.15.tar.gz.
> ===>  Patching for nvidia-driver-325.15
> sed: 1: "/(VM_PROT_READ | VM_PRO ...": invalid command code 0
> *** Error code 1
>
> The Shell/make should be able to substitute within a single-quotet
> command to sed, but the error message reports differently.
>
> Do not be confused about the driver revision I use. I tried the
> official one (319.XX) as well and it is not working the very same way
> and the patch won't either.
>
> Oliver

I don't know about the sed error, but I think the change you're trying
to make is wrong.  The new '0' parameter to vm_map_find() isn't added at
the end, it goes after the size parameter.

-- Ian


_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: CURRENT r255426: x11/nvidia-driver: nvidia_subr.c:835:46: error: too few arguments to function call, expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);

O. Hartmann-4
On Mon, 09 Sep 2013 16:49:23 -0600
Ian Lepore <[hidden email]> wrote:

> On Tue, 2013-09-10 at 00:42 +0200, O. Hartmann wrote:
> > On Tue, 10 Sep 2013 00:24:05 +0300
> > Ivan Klymenko <[hidden email]> wrote:
> >
> > > В Mon, 9 Sep 2013 23:17:13 +0200
> > > "O. Hartmann" <[hidden email]> пишет:
> > >
> > > > On Tue, 10 Sep 2013 00:02:37 +0300
> > > > Ivan Klymenko <[hidden email]> wrote:
> > > >
> > > > > В Mon, 9 Sep 2013 22:37:48 +0200
> > > > > "O. Hartmann" <[hidden email]> пишет:
> > > > > >  /usr/ports/emulators/virtualbox-ose-kmod/work/VirtualBox-4.2.18/out/freebsd.amd64/release/bin/src/vboxdrv/r0drv/freebsd/alloc-r0drv-freebsd.c:83:76:
> > > > > > error: too few arguments to function call, expected 10,
> > > > > > have 9 cbAllocated, TRUE, VM_PROT_ALL, VM_PROT_ALL, 0); ^
> > > > > > @/vm/vm_map.h:368:1: note: 'vm_map_find' declared here int
> > > > > > vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t,
> > > > > > vm_offset_t *, vm_size_t,
> > > > >
> > > > > Try the following changes:
> > > > >         int rc = vm_map_find(kernel_map, pVmObject, 0, &Addr,
> > > > > ---                          cbAllocated, TRUE, VM_PROT_ALL,
> > > > > VM_PROT_ALL, 0); +++                          cbAllocated, 0,
> > > > > VMFS_OPTIMAL_SPACE, VM_PROT_ALL, VM_PROT_ALL, 0);
> > > > >
> > > > > for Nvidia driver need to make similar changes...
> > > > The man page of vm_map_find() says the last parameter is of int,
> > > > named int cow. On the hurry, I didn't find any explanation of
> > > > that parameter. Setting it to "0" (zero) also in the
> > > > nvidia_subr.c makes the driver compile again.
> > > >
> > > > But simply filling in a int zero is a bit strange without
> > > > knowing what to do, isn't it?
> > > >
> > > > Thanks anyway,
> > > >
> > > > Oliver
> > >
> > > This commit you to find an appropriate example ...
> > > http://docs.freebsd.org/cgi/getmsg.cgi?fetch=291456+0+current/svn-src-head
> > > And in this case, the driver Nvidia really need to specify 0 in
> > > place of the sixth argument ...
> > > but I'm not sure at 100% :)
> >
> > I have a patch attached for the x11/nvidia-driver Makefile. It
> > doesn't work and I loose hairs due to not knowing why.
> >
> > When issuing the following command sequence on the console:
> >
> > cd /usr/ports/x11/nvidia-driver
> > make clean extract
> > sed -i -e '/(VM_PROT_READ | VM_PROT_WRITE), 0);$/s/0);$/0, 0);/g' \
> > work/NVIDIA-FreeBSD-x86_64-325.15/src/nvidia_subr.c
> >
> >
> > and check then line 835 (the corrupt one) in file
> > work/NVIDIA-FreeBSD-x86_64-325.15/src/nvidia_subr.c,
> >
> > I see this BEFORE:
> >
> >     status = vm_map_find(kernel_map, at->object, (i * PAGE_SIZE),
> >             &virtual_address, size, VMFS_ANY_SPACE,
> >             (VM_PROT_READ | VM_PROT_WRITE),
> > ===(835)>>            (VM_PROT_READ | VM_PROT_WRITE), 0);
> >
> >
> > and I see this AFTER the sed'ed replacement:
> >
> >     status = vm_map_find(kernel_map, at->object, (i * PAGE_SIZE),
> >             &virtual_address, size, VMFS_ANY_SPACE,
> >             (VM_PROT_READ | VM_PROT_WRITE),
> > ===(835)>>            (VM_PROT_READ | VM_PROT_WRITE), 0, 0);
> >
> > BUT: Using the patch (see attached, please apply to
> > x11/nvidia-driver/Makefile) gives me an error in x11/nvidia-driver:
> >
> > make clean patch
> >
> > ===>  Cleaning for nvidia-driver-325.15
> > ===>  License NVIDIA accepted by the user
> > ===>  Found saved configuration for nvidia-driver-325.08_1
> > ===>   nvidia-driver-325.15 depends on file: /usr/local/sbin/pkg -
> > found ===> Fetching all distfiles required by nvidia-driver-325.15
> > for building
> > ===>  Extracting for nvidia-driver-325.15
> > => SHA256 Checksum OK for NVIDIA-FreeBSD-x86_64-325.15.tar.gz.
> > ===>  Patching for nvidia-driver-325.15
> > sed: 1: "/(VM_PROT_READ | VM_PRO ...": invalid command code 0
> > *** Error code 1
> >
> > The Shell/make should be able to substitute within a single-quotet
> > command to sed, but the error message reports differently.
> >
> > Do not be confused about the driver revision I use. I tried the
> > official one (319.XX) as well and it is not working the very same
> > way and the patch won't either.
> >
> > Oliver
>
> I don't know about the sed error, but I think the change you're trying
> to make is wrong.  The new '0' parameter to vm_map_find() isn't added
> at the end, it goes after the size parameter.
>
> -- Ian
Yes, you're correct and my face is red like a tomatoe :-(

I try this sed replacement expression:
sed -i -e '/\&virtual_address\, size\, \
VMFS_ANY\_SPACE\,$/s//\&virtual_address\, size\, 0\, \
VMFS_ANY\_SPACE\,/g' work/NVIDIA-FreeBSD-x86_64-325.15/src/nvidia_subr.c

It works from the command line, but it doesn't work from the (attached)
Makefile-patch.

nvidia-driver_2nd.patch (597 bytes) Download Attachment
signature.asc (499 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: CURRENT r255426: x11/nvidia-driver: nvidia_subr.c:835:46: error: too few arguments to function call, expected 10, have 9 (VM_PROT_READ | VM_PROT_WRITE), 0);

Olivier Smedts
Hello,


2013/9/10 O. Hartmann <[hidden email]>

> Yes, you're correct and my face is red like a tomatoe :-(
>
> I try this sed replacement expression:
> sed -i -e '/\&virtual_address\, size\, \
> VMFS_ANY\_SPACE\,$/s//\&virtual_address\, size\, 0\, \
> VMFS_ANY\_SPACE\,/g' work/NVIDIA-FreeBSD-x86_64-325.15/src/nvidia_subr.c
>
> It works from the command line, but it doesn't work from the (attached)
> Makefile-patch.
>


A little bit late here (I see a patch has been commited to
x11/nvidia-driver/Makefile, with a shorter sed expression) but your
problems seems to come from make interpreting "$".
The "$/" variable is null, it's stripped from the sed expression which
becomes invalid.
You should escape the "$" inside the sed expression by doubling it.

Cheers

--
Olivier Smedts                                                 _
                                        ASCII ribbon campaign ( )
e-mail: [hidden email]        - against HTML email & vCards  X
www: http://www.gid0.org    - against proprietary attachments / \

  "Il y a seulement 10 sortes de gens dans le monde :
  ceux qui comprennent le binaire,
  et ceux qui ne le comprennent pas."
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "[hidden email]"