Re: CDC-WDM driver (4G modems)
Message: 1 Date: Thu, 11 Sep 2014 15:23:07 +0200 From: Nick Hibma n...@van-laarhoven.org To: freebsd-current@FreeBSD.ORG Cc: Hans Petter Selasky h...@selasky.org Subject: CDC-WDM driver (4G modems) Message-ID: 2d4cf978-b2c2-4253-93c7-595dabac0...@van-laarhoven.org Content-Type: text/plain; charset=us-ascii Folks, Hans-Petter, Is anyone aware of an effort to create support for QMI based 4G modems? The following parts need to be implemented I think: - CDC-WDM support - Wrapper driver to access QMI devices as WDM? - libqmi port to FreeBSD This would support any modem from Telit, Sierra Wireless, Option, etc. that works with the Qualcomm chipsets. If you look in the cdc-wdm qmi driver in Linux, it is a long list. I could not find any mention of FreeBSD and QMI on the same page, so I assume no one is working on it. Actually, I'm working on it. Base part has been done. Currently, just adding more commands. But, I cannot release the code until 3 month after the release of the product. By the way, libqmi is just for QMI commands (controlling the modem). Tx/Rx data packets go though PPP. That's because qualcomm refused to release that part of information. Nick Hibma ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: panic: resource_list_alloc: resource entry is busy
On Wed, 10 Sep 2014, John Baldwin wrote: On Wednesday, September 10, 2014 12:45:08 PM Marcin Cieslak wrote: On my CURRENT as of 6 Sep (r271197): What I did was that: - kldload i915 - startx During X server start I get the following: #10 0x808c2947 in resource_list_alloc (rl=value optimized out, bus=value optimized out, child=value optimized out, type=value optimized out, rid=value optimized out, start=value optimized out, end=value optimized out, count=value optimized out, flags=value optimized out) at /usr/src/sys/kern/subr_bus.c:3304 #11 0x8061ddae in pci_alloc_resource (dev=value optimized out, child=value optimized out, type=value optimized out, rid=value optimized out, start=value optimized out, end=value optimized out, count=value optimized out, flags=value optimized out) at /usr/src/sys/dev/pci/pci.c:4604 #12 0x808c4420 in bus_alloc_resource (dev=0xf800026d8800, type=1, rid=0x811effc8, start=632, end=18446744071580876744, count=464, flags=100707968) at bus_if.h:284 #13 0x80626092 in vga_pci_alloc_resource (dev=0xf800026d8800, child=value optimized out, type=1, rid=0xf80008c0b2d4, start=0, end=value optimized out, count=18446744071580876744, flags=value optimized out) at /usr/src/sys/dev/pci/vga_pci.c:318 Can you load the core dump in kgdb and run 'f 13' and 'p *rid'? Sure, here it goes: (kgdb) f 13 #13 0x80626092 in vga_pci_alloc_resource ( dev=0xf800026d8800, child=value optimized out, type=1, rid=0xf80008c0b2d4, start=0, end=value optimized out, count=18446744071580876744, flags=value optimized out) at /usr/src/sys/dev/pci/vga_pci.c:318 318 return (bus_alloc_resource(dev, type, rid, start, end, count, flags)); Current language: auto; currently minimal (kgdb) p *rid $1 = 0 //Marcin ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: panic: resource_list_alloc: resource entry is busy
On Friday, September 12, 2014 05:45:31 PM Marcin Cieslak wrote: On Wed, 10 Sep 2014, John Baldwin wrote: On Wednesday, September 10, 2014 12:45:08 PM Marcin Cieslak wrote: On my CURRENT as of 6 Sep (r271197): What I did was that: - kldload i915 - startx During X server start I get the following: #10 0x808c2947 in resource_list_alloc (rl=value optimized out, bus=value optimized out, child=value optimized out, type=value optimized out, rid=value optimized out, start=value optimized out, end=value optimized out, count=value optimized out, flags=value optimized out) at /usr/src/sys/kern/subr_bus.c:3304 #11 0x8061ddae in pci_alloc_resource (dev=value optimized out, child=value optimized out, type=value optimized out, rid=value optimized out, start=value optimized out, end=value optimized out, count=value optimized out, flags=value optimized out) at /usr/src/sys/dev/pci/pci.c:4604 #12 0x808c4420 in bus_alloc_resource (dev=0xf800026d8800, type=1, rid=0x811effc8, start=632, end=18446744071580876744, count=464, flags=100707968) at bus_if.h:284 #13 0x80626092 in vga_pci_alloc_resource (dev=0xf800026d8800, child=value optimized out, type=1, rid=0xf80008c0b2d4, start=0, end=value optimized out, count=18446744071580876744, flags=value optimized out) at /usr/src/sys/dev/pci/vga_pci.c:318 Can you load the core dump in kgdb and run 'f 13' and 'p *rid'? Sure, here it goes: (kgdb) f 13 #13 0x80626092 in vga_pci_alloc_resource ( dev=0xf800026d8800, child=value optimized out, type=1, rid=0xf80008c0b2d4, start=0, end=value optimized out, count=18446744071580876744, flags=value optimized out) at /usr/src/sys/dev/pci/vga_pci.c:318 318 return (bus_alloc_resource(dev, type, rid, start, end, count, flags)); Current language: auto; currently minimal (kgdb) p *rid $1 = 0 Hmm, type 1 is SYS_RES_IRQ. IRQ resources should not be marked reserved. Oh, some other child of vgapci has already allocated the IRQ. That seems odd. Can you get 'devinfo -r' output before you kldload i915kms and again after doing the kldload? (No need to run startx) -- John Baldwin ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: panic: resource_list_alloc: resource entry is busy
On Fri, 12 Sep 2014, John Baldwin wrote: at /usr/src/sys/dev/pci/vga_pci.c:318 318 return (bus_alloc_resource(dev, type, rid, start, end, count, flags)); Current language: auto; currently minimal (kgdb) p *rid $1 = 0 Hmm, type 1 is SYS_RES_IRQ. IRQ resources should not be marked reserved. Oh, some other child of vgapci has already allocated the IRQ. That seems odd. Can you get 'devinfo -r' output before you kldload i915kms and again after doing the kldload? (No need to run startx) Please note I originally loaded i915.ko, not i915kms.ko Full output of the devinfo -r attached (no modules, w/i915 and w/i915kms), snippets: pcib0 I/O ports: 0xcf8-0xcff pci0 PCI domain 0 bus numbers: 0 hostb0 vgapci0 I/O ports: 0x1800-0x1807 I/O memory addresses: 0xd000-0xdfff 0xf830-0xf837 0xf840-0xf843 agp0 I/O memory addresses: 0x8000-0x8fff acpi_video0 vgapci1 I/O memory addresses: 0xf838-0xf83f With i915.ko loaded: pcib0 I/O ports: 0xcf8-0xcff pci0 PCI domain 0 bus numbers: 0 hostb0 vgapci0 Interrupt request lines: 16 I/O ports: 0x1800-0x1807 I/O memory addresses: 0xd000-0xdfff 0xf830-0xf837 0xf840-0xf843 agp0 I/O memory addresses: 0x8000-0x8fff acpi_video0 drm0 vgapci1 I/O memory addresses: 0xf838-0xf83f with i915kms.ko loaded: pcib0 I/O ports: 0xcf8-0xcff pci0 PCI domain 0 bus numbers: 0 hostb0 vgapci0 Interrupt request lines: 16 I/O ports: 0x1800-0x1807 I/O memory addresses: 0xd000-0xdfff 0xf830-0xf837 0xf840-0xf843 agp0 I/O memory addresses: 0x8000-0x8fff acpi_video0 drmn0 intel_iicbb0 iicbb0 iicbus0 iicsmb0 smbus0 smb0 iic0 intel_gmbus0 iicbus1 iicsmb1 smbus1 smb1 iic1 intel_iicbb1 iicbb1 iicbus2 iicsmb2 smbus2 smb2 iic2 intel_gmbus1 iicbus3 iicsmb3 smbus3 smb3 iic3 intel_iicbb2 iicbb2 iicbus4 iicsmb4 smbus4 smb4 iic4 intel_gmbus2 iicbus5 iicsmb5 smbus5 smb5 iic5 intel_iicbb3 iicbb3 iicbus6 iicsmb6 smbus6 smb6 iic6 intel_gmbus3 iicbus7 iicsmb7 smbus7 smb7 iic7 intel_iicbb4 iicbb4 iicbus8 iicsmb8 smbus8 smb8 iic8 intel_gmbus4 iicbus9 iicsmb9 smbus9 smb9 iic9 intel_iicbb5 iicbb5 iicbus10 iicsmb10 smbus10 smb10 iic10 intel_gmbus5 iicbus11 iicsmb11 smbus11 smb11 iic11 intel_iicbb6 iicbb6 iicbus12 iicsmb12 smbus12 smb12 iic12 intel_gmbus6 iicbus13 iicsmb13 smbus13 smb13 iic13 intel_iicbb7 iicbb7 iicbus14 iicsmb14 smbus14 smb14 iic14 intel_gmbus7 iicbus15 iicsmb15 smbus15 smb15 iic15 fbd0 vgapci1
shells/bash port, add a knob which symlinks to /bin/bash ?
Hi, In the last 3 jobs that I have worked at, there have been a mix of Linux machines and FreeBSD machines. When using an NIS or LDAP environment where there is a single login across multiple machines, it is useful to have a single shell setting. Since Linux and MacOS X have /bin/bash as the shell, in order to get the FreeBSD boxes to play in this environment, I have seen admins do the following on FreeBSD setups: ln -s /usr/local/bin/bash /bin/bash or ln /usr/local/bin/bash /bin/bash and then make sure that /etc/shells as: /usr/local/bin/bash /bin/bash Can we add an optional knob (turned off by default) which creates this symlink and updates /etc/shells? This would help with interoperability of FreeBSD hosts in environments mixed with Linux and MacOS X. -- Craig ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
No (as portmgr). Ports should not be touching the base system like this. Let's NOT go backwards and add a /bin/bash. In fact the /usr/bin/perl one will be removed soon as well. If we can actually eliminate ports touching /usr and / (not including /usr/local and /var) then we gain a very large memory optimization for package building by being able to ro null-mount these to the build jails. There's no reason for bash (and perl) to be exceptions to the 24000 other ports that install to /usr/local/bin. I can think of dozens of other ports that will fall into the same arguments being made here, but it does not mean it is the right thing for FreeBSD. If you want to install the symlink on your system feel free to do it. I install a static bash to /bin/bash on mine and only because I prefer bash shell and want it in / for single-user mode. That's my personal choice though. The proper fix is to fix scripts to be portable and use #! /usr/bin/env bash rather than /bin/bash. We install all packages to PREFIX=/usr/local by default. Why should a bin symlink be an exception? There's no suggestion for symlinking includes or libraries which also hit users often. On 9/12/2014 4:12 PM, Craig Rodrigues wrote: Hi, In the last 3 jobs that I have worked at, there have been a mix of Linux machines and FreeBSD machines. When using an NIS or LDAP environment where there is a single login across multiple machines, it is useful to have a single shell setting. Since Linux and MacOS X have /bin/bash as the shell, in order to get the FreeBSD boxes to play in this environment, I have seen admins do the following on FreeBSD setups: ln -s /usr/local/bin/bash /bin/bash or ln /usr/local/bin/bash /bin/bash and then make sure that /etc/shells as: /usr/local/bin/bash /bin/bash Can we add an optional knob (turned off by default) which creates this symlink and updates /etc/shells? This would help with interoperability of FreeBSD hosts in environments mixed with Linux and MacOS X. -- Craig ___ freebsd-po...@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-ports To unsubscribe, send any mail to freebsd-ports-unsubscr...@freebsd.org -- Regards, Bryan Drewery signature.asc Description: OpenPGP digital signature
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
On Fri, Sep 12, 2014 at 02:12:45PM -0700, Craig Rodrigues wrote: Hi, In the last 3 jobs that I have worked at, there have been a mix of Linux machines and FreeBSD machines. When using an NIS or LDAP environment where there is a single login across multiple machines, it is useful to have a single shell setting. Since Linux and MacOS X have /bin/bash as the shell, in order to get the FreeBSD boxes to play in this environment, I have seen admins do the following on FreeBSD setups: ln -s /usr/local/bin/bash /bin/bash or ln /usr/local/bin/bash /bin/bash and then make sure that /etc/shells as: /usr/local/bin/bash /bin/bash Can we add an optional knob (turned off by default) which creates this symlink and updates /etc/shells? This would help with interoperability of FreeBSD hosts in environments mixed with Linux and MacOS X. Please no, no and no! We are fighting for a very long time to prevent the ports to pollute base. We have added the shebangfix USES to be able to catch with up with cleanup this properly as well as a qa test to discover it automatically. no interpreters at all have a symlink in base but perl and this one is going to be removed. If you want interoperability just use /usr/bin/env bash as a shebang. Btw you cannot get interoprability with OS-X in there because the bash they do provide is the last GPL-2 recent bash have many incompatiblities with this old version. regards, Bapt pgpQHo4ikWIyu.pgp Description: PGP signature
RE: shells/bash port, add a knob which symlinks to /bin/bash ?
If you want interoperability just use /usr/bin/env bash as a shebang. That doesn't work for this use case -- the user shell coming from LDAP -- but I agree that the port shouldn't be modifying /usr/bin. It's easy enough to add the symlink manually after installing the port if you're in this situation, or there may be a way to configure the LDAP module to map /bin/bash to /usr/local/bin/bash (I haven't looked to see what is supported here). Anton ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
RE: shells/bash port, add a knob which symlinks to /bin/bash ?
On Fri, 12 Sep 2014, Rang, Anton wrote: If you want interoperability just use /usr/bin/env bash as a shebang. That doesn't work for this use case -- the user shell coming from LDAP -- but I agree that the port shouldn't be modifying /usr/bin. Here at MIT, where our Athena environment has a long history of providing a consistent experience across many different platforms, we ended up limiting the login shells a user could select, to a whitelist we provide (/bin/sh, /usr/athena/bin/bash, and /usr/athena/bin/tcsh). (The latter two are now symlinks to the normal system shells, but they used to be custom binaries.) Some people did not like being so restricted, and set their login shell to /bin/sh, with logic in their dotfiles to re-exec a different shell depending on the current runtime environment. -Ben ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: panic: resource_list_alloc: resource entry is busy
On Friday, September 12, 2014 08:57:55 PM Marcin Cieslak wrote: On Fri, 12 Sep 2014, John Baldwin wrote: at /usr/src/sys/dev/pci/vga_pci.c:318 318return (bus_alloc_resource(dev, type, rid, start, end, count, flags)); Current language: auto; currently minimal (kgdb) p *rid $1 = 0 Hmm, type 1 is SYS_RES_IRQ. IRQ resources should not be marked reserved. Oh, some other child of vgapci has already allocated the IRQ. That seems odd. Can you get 'devinfo -r' output before you kldload i915kms and again after doing the kldload? (No need to run startx) Please note I originally loaded i915.ko, not i915kms.ko Oh, that is probably your problem. X loaded i915kms automatically and i915 and i915kms do not get along. i915 had already allocated the IRQ when i915kms tried to alloc the same IRQ causing the issue. -- John Baldwin ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
The correct thing is to make a port/pkg that installs the symlink and /etc/shells this for the user. There is no need for changes to 'base' nor do we need a change to the system port. -Alfred On 9/12/14 2:40 PM, Baptiste Daroussin wrote: On Fri, Sep 12, 2014 at 02:12:45PM -0700, Craig Rodrigues wrote: Hi, In the last 3 jobs that I have worked at, there have been a mix of Linux machines and FreeBSD machines. When using an NIS or LDAP environment where there is a single login across multiple machines, it is useful to have a single shell setting. Since Linux and MacOS X have /bin/bash as the shell, in order to get the FreeBSD boxes to play in this environment, I have seen admins do the following on FreeBSD setups: ln -s /usr/local/bin/bash /bin/bash or ln /usr/local/bin/bash /bin/bash and then make sure that /etc/shells as: /usr/local/bin/bash /bin/bash Can we add an optional knob (turned off by default) which creates this symlink and updates /etc/shells? This would help with interoperability of FreeBSD hosts in environments mixed with Linux and MacOS X. Please no, no and no! We are fighting for a very long time to prevent the ports to pollute base. We have added the shebangfix USES to be able to catch with up with cleanup this properly as well as a qa test to discover it automatically. no interpreters at all have a symlink in base but perl and this one is going to be removed. If you want interoperability just use /usr/bin/env bash as a shebang. Btw you cannot get interoprability with OS-X in there because the bash they do provide is the last GPL-2 recent bash have many incompatiblities with this old version. regards, Bapt ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: panic: resource_list_alloc: resource entry is busy
On Fri, 12 Sep 2014, John Baldwin wrote: Please note I originally loaded i915.ko, not i915kms.ko Oh, that is probably your problem. X loaded i915kms automatically and i915 and i915kms do not get along. i915 had already allocated the IRQ when i915kms tried to alloc the same IRQ causing the issue. Would that be possible to fail with EBUSY or something instead of panic? //Marcin ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
On Sep 12, 2014, at 14:53, Benjamin Kaduk ka...@mit.edu wrote: On Fri, 12 Sep 2014, Rang, Anton wrote: If you want interoperability just use /usr/bin/env bash as a shebang. That doesn't work for this use case -- the user shell coming from LDAP -- but I agree that the port shouldn't be modifying /usr/bin. Here at MIT, where our Athena environment has a long history of providing a consistent experience across many different platforms, we ended up limiting the login shells a user could select, to a whitelist we provide (/bin/sh, /usr/athena/bin/bash, and /usr/athena/bin/tcsh). (The latter two are now symlinks to the normal system shells, but they used to be custom binaries.) Some people did not like being so restricted, and set their login shell to /bin/sh, with logic in their dotfiles to re-exec a different shell depending on the current runtime environment. +1 user rc files (not that it would fix this particular case...): - https://github.com/yaneurabeya/scratch/blob/master/bayonetta/home/ngie/dot.bashrc - https://github.com/yaneurabeya/scratch/blob/master/bayonetta/home/ngie/dot.shrc-local Cheers, -Garrett signature.asc Description: Message signed with OpenPGP using GPGMail
RE: shells/bash port, add a knob which symlinks to /bin/bash ?
On Fri, 12 Sep 2014, Rang, Anton wrote: If you want interoperability just use /usr/bin/env bash as a shebang. That doesn't work for this use case -- the user shell coming from LDAP -- but I agree that the port shouldn't be modifying /usr/bin. It's easy enough to add the symlink manually after installing the port if you're in this situation, or there may be a way to configure the LDAP module to map /bin/bash to /usr/local/bin/bash (I haven't looked to see what is supported here). We have used LDAP on Solaris for years, and have mixed environments of Solaris, Linux, and FreeBSD. We use /usr/local/bin/bash in LDAP for shells, then either link that to the system /bin/bash or install more up-to-date bash in /usr/local/bin. This way you can always install a more up-to-date shell in /usr/local/bin without changing the base OS - you don't want base OS shell scripts to break by updating to a newer shell. -- DE ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
On Sep 12, 2014, at 2:40 PM, Baptiste Daroussin b...@freebsd.org wrote: If you want interoperability just use /usr/bin/env bash as a shebang. Btw you cannot get interoprability with OS-X in there because the bash they do provide is the last GPL-2 recent bash have many incompatiblities with this old version. The concern is not with shell scripts, it's with the contents of the pw_shell field in 'struct passwd'. I run into this all the time, too, but with ksh. In my case I just cp a static-linked version of whatever ksh variant I happened to build into /bin/ksh and call it a day. It's not like the shell source code is changing every other week, even for bash. --lyndon signature.asc Description: Message signed with OpenPGP using GPGMail
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
Hi, I could live with this solution of additional port outside of the main bash port, which creates the symlink and updates /etc/shells. One other thing I am seeing is that many, many shell scripts are written assuming #!/bin/bash. Forcing all upstream script writers to switch to #!/usr/bin/env bash, or to convert their scripts to #!/bin/sh and remove all bash-specific behaviors, is getting harder and harder, since many people are exposed to MacOS X and Linux on desktops. -- Craig On Fri, Sep 12, 2014 at 3:02 PM, Alfred Perlstein bri...@mu.org wrote: The correct thing is to make a port/pkg that installs the symlink and /etc/shells this for the user. There is no need for changes to 'base' nor do we need a change to the system port. -Alfred On 9/12/14 2:40 PM, Baptiste Daroussin wrote: On Fri, Sep 12, 2014 at 02:12:45PM -0700, Craig Rodrigues wrote: Hi, In the last 3 jobs that I have worked at, there have been a mix of Linux machines and FreeBSD machines. When using an NIS or LDAP environment where there is a single login across multiple machines, it is useful to have a single shell setting. Since Linux and MacOS X have /bin/bash as the shell, in order to get the FreeBSD boxes to play in this environment, I have seen admins do the following on FreeBSD setups: ln -s /usr/local/bin/bash /bin/bash or ln /usr/local/bin/bash /bin/bash and then make sure that /etc/shells as: /usr/local/bin/bash /bin/bash Can we add an optional knob (turned off by default) which creates this symlink and updates /etc/shells? This would help with interoperability of FreeBSD hosts in environments mixed with Linux and MacOS X. Please no, no and no! We are fighting for a very long time to prevent the ports to pollute base. We have added the shebangfix USES to be able to catch with up with cleanup this properly as well as a qa test to discover it automatically. no interpreters at all have a symlink in base but perl and this one is going to be removed. If you want interoperability just use /usr/bin/env bash as a shebang. Btw you cannot get interoprability with OS-X in there because the bash they do provide is the last GPL-2 recent bash have many incompatiblities with this old version. regards, Bapt ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
On Sat, Sep 13, 2014 at 2:23 AM, Craig Rodrigues rodr...@freebsd.org wrote: Hi, I could live with this solution of additional port outside of the main bash port, which creates the symlink and updates /etc/shells. One other thing I am seeing is that many, many shell scripts are written assuming #!/bin/bash. Forcing all upstream script writers to switch to #!/usr/bin/env bash, or to convert their scripts to #!/bin/sh and remove all bash-specific behaviors, is getting harder and harder, since many people are exposed to MacOS X and Linux on desktops. -- Craig On Fri, Sep 12, 2014 at 3:02 PM, Alfred Perlstein bri...@mu.org wrote: The correct thing is to make a port/pkg that installs the symlink and /etc/shells this for the user. There is no need for changes to 'base' nor do we need a change to the system port. -Alfred On 9/12/14 2:40 PM, Baptiste Daroussin wrote: On Fri, Sep 12, 2014 at 02:12:45PM -0700, Craig Rodrigues wrote: Hi, In the last 3 jobs that I have worked at, there have been a mix of Linux machines and FreeBSD machines. When using an NIS or LDAP environment where there is a single login across multiple machines, it is useful to have a single shell setting. Since Linux and MacOS X have /bin/bash as the shell, in order to get the FreeBSD boxes to play in this environment, I have seen admins do the following on FreeBSD setups: ln -s /usr/local/bin/bash /bin/bash or ln /usr/local/bin/bash /bin/bash and then make sure that /etc/shells as: /usr/local/bin/bash /bin/bash Can we add an optional knob (turned off by default) which creates this symlink and updates /etc/shells? This would help with interoperability of FreeBSD hosts in environments mixed with Linux and MacOS X. Please no, no and no! We are fighting for a very long time to prevent the ports to pollute base. We have added the shebangfix USES to be able to catch with up with cleanup this properly as well as a qa test to discover it automatically. no interpreters at all have a symlink in base but perl and this one is going to be removed. If you want interoperability just use /usr/bin/env bash as a shebang. Btw you cannot get interoprability with OS-X in there because the bash they do provide is the last GPL-2 recent bash have many incompatiblities with this old version. regards, Bapt Looks like variant symlink is may be useful for solving this problem and it is not cluttered base https://wiki.freebsd.org/200808DevSummit?action=AttachFiledo=gettarget=variant-symlinks-for-freebsd.pdf ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
On Sat, Sep 13, 2014 at 02:33:58AM +0400, Subbsd wrote: On Sat, Sep 13, 2014 at 2:23 AM, Craig Rodrigues rodr...@freebsd.org wrote: Hi, I could live with this solution of additional port outside of the main bash port, which creates the symlink and updates /etc/shells. This is the approach I took at my previous employer. It's simple, works with packages, and people who hate adding things to /bin can avoid doing so. Looks like variant symlink is may be useful for solving this problem and it is not cluttered base https://wiki.freebsd.org/200808DevSummit?action=AttachFiledo=gettarget=variant-symlinks-for-freebsd.pdf As the person who ported variant symlinks to FreeBSD I can't image how they could be useful here. If you need a /bin/bash you need to put a file system object there (or I supposed hack namei). Variant symlinks only allow files to point to different things in different contexts. -- Brooks pgpwRGL3Gwnqy.pgp Description: PGP signature
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
On Sep 12, 2014, at 3:23 PM, Craig Rodrigues rodr...@freebsd.org wrote: Forcing all upstream script writers to switch to #!/usr/bin/env bash, or to convert their scripts to #!/bin/sh and remove all bash-specific behaviors, is getting harder and harder, since many people are exposed to MacOS X and Linux on desktops. Given the rigid nature of shebangs to begin with, it's really not that hard to write a sed command that will capture all instances of '#!.../bash[ foo]' and wire in an appropriate value of '...'. In fact, this case is a ripe candidate for a bsd.port.mk command macro. --lyndon signature.asc Description: Message signed with OpenPGP using GPGMail
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
On 9/12/2014 5:45 PM, Lyndon Nerenberg wrote: On Sep 12, 2014, at 3:23 PM, Craig Rodrigues rodr...@freebsd.org wrote: Forcing all upstream script writers to switch to #!/usr/bin/env bash, or to convert their scripts to #!/bin/sh and remove all bash-specific behaviors, is getting harder and harder, since many people are exposed to MacOS X and Linux on desktops. Given the rigid nature of shebangs to begin with, it's really not that hard to write a sed command that will capture all instances of '#!.../bash[ foo]' and wire in an appropriate value of '...'. In fact, this case is a ripe candidate for a bsd.port.mk command macro. --lyndon There already is one and ports requires using it! -- Regards, Bryan Drewery signature.asc Description: OpenPGP digital signature
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
On Sep 12, 2014, at 3:55 PM, Bryan Drewery bdrew...@freebsd.org wrote: There already is one and ports requires using it! Doh! signature.asc Description: Message signed with OpenPGP using GPGMail
Re: shells/bash port, add a knob which symlinks to /bin/bash ?
On 9/12/14 3:23 PM, Craig Rodrigues wrote: Hi, I could live with this solution of additional port outside of the main bash port, which creates the symlink and updates /etc/shells. One other thing I am seeing is that many, many shell scripts are written assuming #!/bin/bash. Forcing all upstream script writers to switch to #!/usr/bin/env bash, or to convert their scripts to #!/bin/sh and remove all bash-specific behaviors, is getting harder and harder, since many people are exposed to MacOS X and Linux on desktops. Lol, or we could hack the image activator. :) -Alfred ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: panic: resource_list_alloc: resource entry is busy
On Fri, Sep 12, 2014 at 1:57 PM, Marcin Cieslak sa...@saper.info wrote: On Fri, 12 Sep 2014, John Baldwin wrote: at /usr/src/sys/dev/pci/vga_pci.c:318 318 return (bus_alloc_resource(dev, type, rid, start, end, count, flags)); Current language: auto; currently minimal (kgdb) p *rid $1 = 0 Hmm, type 1 is SYS_RES_IRQ. IRQ resources should not be marked reserved. Oh, some other child of vgapci has already allocated the IRQ. That seems odd. Can you get 'devinfo -r' output before you kldload i915kms and again after doing the kldload? (No need to run startx) Please note I originally loaded i915.ko, not i915kms.ko Unfortunately, kldunload i915kms makes my screen blank and probably crashes the system (disk activity stops after a short while and there is no response to the keyboard input). //Marcin That explains most of it. You need i915kms. It is conflicting with i915 which already has the IRQ allocated. The black screen is expected. Once KMS starts talking to the graphics system, syscons can no longer talk to the display, so you get a black screen. To have a working display, you must enable vt(4). Add kern.vty=vt to /boot/loader.conf to enable vt(4) which will keep the display alive. -- R. Kevin Oberman, Network Engineer, Retired E-mail: rkober...@gmail.com ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org
Re: _ftello() modification requires additional capsicum rights, breaking tcpdump and dhclient
On Thursday, September 11, 2014 12:38:02 PM Patrick Kelsey wrote: On Wed, Sep 10, 2014 at 3:00 AM, Andrey Chernov a...@freebsd.org wrote: On 09.09.2014 21:53, Patrick Kelsey wrote: I don't think it is worth the trouble, as given the larger pattern of libc routines requiring multiple capsicum rights, it seems one will in general have to have libc implementation knowledge when using it in concert with capsicum. For example, consider the limitfd() routine in kdump.c, which provides rights for the TIOCGETA ioctl to be used on stdout so the eventual call to isatty() via printf() will work as intended. I think the above kdump example is a good one for the subtle issues that can arise when using capsicum with libc. That call to isatty() is via a widely-used internal libc routine __smakebuf(). __smakebuf() also calls __swhatbuf(), which in turn calls _fstat(), all to make sure that output to a tty is line buffered by default. It would appear that programs that restrict rights on stdout without allowing CAP_IOCTL and CAP_FSTAT could be disabling the normally default line buffering when stdout is a tty. kdump goes the distance, but dhclient does not (restricting stdout to CAP_WRITE only). In any event, the patch attached to my first message is seeming like the way to go. Well, then commit it (if capsicum team agrees). Will do - thanks for the feedback. -Patrick Is there any possibility that this is related to the problem we've recently hit in the freebsd.org cluster with this month's refresh? After running for a while: Sep 10 02:39:44 ns2 unbound: [65258:0] notice: init module 0: validator Sep 10 02:39:44 ns2 unbound: [65258:0] notice: init module 1: iterator Sep 10 11:44:29 ns2 unbound: [65258:3] fatal error: event_dispatch returned error -1, errno is Capabilities insufficient Sep 10 16:21:16 ns2 unbound: [28212:0] warning: did not exit gracefully last time (65258) Sep 10 16:21:16 ns2 unbound: [28213:0] notice: init module 0: validator Sep 10 16:21:16 ns2 unbound: [28213:0] notice: init module 1: iterator Sep 11 10:23:49 ns2 unbound: [28213:5] fatal error: event_dispatch returned error -1, errno is Capabilities insufficient Sep 11 13:48:46 ns2 unbound: [79419:0] warning: did not exit gracefully last time (28213) Sep 11 13:48:46 ns2 unbound: [79420:0] notice: init module 0: validator Sep 11 13:48:46 ns2 unbound: [79420:0] notice: init module 1: iterator Sep 11 18:42:56 ns2 unbound: [79420:6] fatal error: event_dispatch returned error -1, errno is Capabilities insufficient I believe this jail was started from the boot process. If I restart the jail by hand from a ssh session the problem goes away. This is unbound from ports and I don't have any more details than this. This is new this month. -- Peter Wemm - pe...@wemm.org; pe...@freebsd.org; pe...@yahoo-inc.com; KI6FJV UTF-8: for when a ' or ... just won\342\200\231t do\342\200\246 signature.asc Description: This is a digitally signed message part.