Quantcast

Precisely what hardware information is required?

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Precisely what hardware information is required?

nvangogh-2
Hello,
I am a novice as far as FreeBSD is concerned. However, I am interested
in device driver development methodology and code.

My question relates specifically to a particular wireless chipset for
wifi. There is currently no device driver available under FreeBSD for
the RTL 8191 SE chipset. Realtek have a web page explaining the features
of the chip in general terms. There is source code available for certain
linux distributions. Now I understand that it would be impossible to
build such source code on FreeBSD.

However, according to the documentation, the source code is divided into
two parts i.e :

1. Firmware for the chip. There is a folder that contains 7 small files
(on average 70kb) and they end with .bin.fw - I believe that these are
the files containing assembly code for the chipset. How would one go
about writing such code from scratch, with only general information
about the driver? Would it be necessary to have technical information
such as the number of registers in the chipset and eg how they interact?
Or Is there a generic codebase of 'firmware' that will work with most
wifi chipsets? What does the firmware actually do?

2. Source code. This is written in c. At this stage I have no questions
about it.

Kind Regards




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

TFTPing file from server with Softlink

Ravi Shankar-17

Hi,
 I am trying to TFTP a file from the server running FreeBSD 6.2 based OS where the file is a symbolic link to a a file in another partition.
The TFTP server is failing saying no SUCH FILE ( Validate_access fails), but when I copy the file locally, the server responds and file is FTPd.
Can you some one help me what should I change to get the file working thru soft or symbolic links ( even symbolic link within same partition does not work !!)
Any chroot permission I need to change?
Thanks,
Ravi
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: TFTPing file from server with Softlink

Jess Disney
Use WinSCP. GUI way to FTP/SCP


Thanks for your time,

--
Jess Disney
615-280-0582


On Thu, Jul 26, 2012 at 4:32 PM, Ravi Shankar <[hidden email]> wrote:

>
> Hi,
>  I am trying to TFTP a file from the server running FreeBSD 6.2 based OS
> where the file is a symbolic link to a a file in another partition.
> The TFTP server is failing saying no SUCH FILE ( Validate_access fails),
> but when I copy the file locally, the server responds and file is FTPd.
> Can you some one help me what should I change to get the file working thru
> soft or symbolic links ( even symbolic link within same partition does not
> work !!)
> Any chroot permission I need to change?
> Thanks,
> Ravi
> _______________________________________________
> [hidden email] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
> To unsubscribe, send any mail to "[hidden email]"
>
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: TFTPing file from server with Softlink

Warner Losh
In reply to this post by Ravi Shankar-17

On Jul 26, 2012, at 3:32 PM, Ravi Shankar wrote:

>
> Hi,
>  I am trying to TFTP a file from the server running FreeBSD 6.2 based OS where the file is a symbolic link to a a file in another partition.
> The TFTP server is failing saying no SUCH FILE ( Validate_access fails), but when I copy the file locally, the server responds and file is FTPd.
> Can you some one help me what should I change to get the file working thru soft or symbolic links ( even symbolic link within same partition does not work !!)
> Any chroot permission I need to change?

If you really are chrooted, then you can't have a symbolic link to another partition since that's not part of the chroot...

Warner


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

Re: TFTPing file from server with Softlink

Warner Losh
In reply to this post by Jess Disney

On Jul 26, 2012, at 3:37 PM, Jess Disney wrote:
> Use WinSCP. GUI way to FTP/SCP

*T*FTP.  This is likely for an embedded device or PXE booted server.  Neither is likely to have WinSCP, and besides, that doesn't support TFTP last time I used it.

Warner


>
> Thanks for your time,
>
> --
> Jess Disney
> 615-280-0582
>
>
> On Thu, Jul 26, 2012 at 4:32 PM, Ravi Shankar <[hidden email]> wrote:
>
>>
>> Hi,
>> I am trying to TFTP a file from the server running FreeBSD 6.2 based OS
>> where the file is a symbolic link to a a file in another partition.
>> The TFTP server is failing saying no SUCH FILE ( Validate_access fails),
>> but when I copy the file locally, the server responds and file is FTPd.
>> Can you some one help me what should I change to get the file working thru
>> soft or symbolic links ( even symbolic link within same partition does not
>> work !!)
>> Any chroot permission I need to change?
>> Thanks,
>> Ravi
>> _______________________________________________
>> [hidden email] mailing list
>> http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
>> To unsubscribe, send any mail to "[hidden email]"
>>
> _______________________________________________
> [hidden email] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
> To unsubscribe, send any mail to "[hidden email]"

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

Re: TFTPing file from server with Softlink

Ravi Shankar-17
I have use tftp as I am trying to load the file from a server running on a different blade and the line card running Uboot is trying to load the microkernel thru tftp boot.

--- On Thu, 7/26/12, Warner Losh <[hidden email]> wrote:

From: Warner Losh <[hidden email]>
Subject: Re: TFTPing file from server with Softlink
To: "Jess Disney" <[hidden email]>
Cc: "Ravi Shankar" <[hidden email]>, [hidden email], "nvangogh" <[hidden email]>
Date: Thursday, July 26, 2012, 2:58 PM


On Jul 26, 2012, at 3:37 PM, Jess Disney wrote:
> Use WinSCP. GUI way to FTP/SCP

*T*FTP.  This is likely for an embedded device or PXE booted server.  Neither is likely to have WinSCP, and besides, that doesn't support TFTP last time I used it.

Warner


>
> Thanks for your time,
>
> --
> Jess Disney
> 615-280-0582
>
>
> On Thu, Jul 26, 2012 at 4:32 PM, Ravi Shankar <[hidden email]> wrote:
>
>>
>> Hi,
>> I am trying to TFTP a file from the server running FreeBSD 6.2 based OS
>> where the file is a symbolic link to a a file in another partition.
>> The TFTP server is failing saying no SUCH FILE ( Validate_access fails),
>> but when I copy the file locally, the server responds and file is FTPd.
>> Can you some one help me what should I change to get the file working thru
>> soft or symbolic links ( even symbolic link within same partition does not
>> work !!)
>> Any chroot permission I need to change?
>> Thanks,
>> Ravi
>> _______________________________________________
>> [hidden email] mailing list
>> http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
>> To unsubscribe, send any mail to "[hidden email]"
>>
> _______________________________________________
> [hidden email] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
> To unsubscribe, send any mail to "[hidden email]"

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

Re: TFTPing file from server with Softlink

Warner Losh

On Jul 26, 2012, at 5:02 PM, Ravi Shankar wrote:

> I have use tftp as I am trying to load the file from a server running on a different blade and the line card running Uboot is trying to load the microkernel thru tftp boot.

I understand that.  tftpd often runs in a chroot.  In a chroot, you can't symlink to a file outside the chroot and have it work.

Warner

> --- On Thu, 7/26/12, Warner Losh <[hidden email]> wrote:
>
> From: Warner Losh <[hidden email]>
> Subject: Re: TFTPing file from server with Softlink
> To: "Jess Disney" <[hidden email]>
> Cc: "Ravi Shankar" <[hidden email]>, [hidden email], "nvangogh" <[hidden email]>
> Date: Thursday, July 26, 2012, 2:58 PM
>
>
> On Jul 26, 2012, at 3:37 PM, Jess Disney wrote:
> > Use WinSCP. GUI way to FTP/SCP
>
> *T*FTP.  This is likely for an embedded device or PXE booted server.  Neither is likely to have WinSCP, and besides, that doesn't support TFTP last time I used it.
>
> Warner
>
>
> >
> > Thanks for your time,
> >
> > --
> > Jess Disney
> > 615-280-0582
> >
> >
> > On Thu, Jul 26, 2012 at 4:32 PM, Ravi Shankar <[hidden email]> wrote:
> >
> >>
> >> Hi,
> >> I am trying to TFTP a file from the server running FreeBSD 6.2 based OS
> >> where the file is a symbolic link to a a file in another partition.
> >> The TFTP server is failing saying no SUCH FILE ( Validate_access fails),
> >> but when I copy the file locally, the server responds and file is FTPd.
> >> Can you some one help me what should I change to get the file working thru
> >> soft or symbolic links ( even symbolic link within same partition does not
> >> work !!)
> >> Any chroot permission I need to change?
> >> Thanks,
> >> Ravi
> >> _______________________________________________
> >> [hidden email] mailing list
> >> http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
> >> To unsubscribe, send any mail to "[hidden email]"
> >>
> > _______________________________________________
> > [hidden email] mailing list
> > http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
> > To unsubscribe, send any mail to "[hidden email]"
>

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

Re: Precisely what hardware information is required?

Xin LI-2
In reply to this post by nvangogh-2
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 07/14/12 08:07, nvangogh wrote:

> Hello, I am a novice as far as FreeBSD is concerned. However, I am
> interested in device driver development methodology and code.
>
> My question relates specifically to a particular wireless chipset
> for wifi. There is currently no device driver available under
> FreeBSD for the RTL 8191 SE chipset. Realtek have a web page
> explaining the features of the chip in general terms. There is
> source code available for certain linux distributions. Now I
> understand that it would be impossible to build such source code on
> FreeBSD.
>
> However, according to the documentation, the source code is divided
> into two parts i.e :
>
> 1. Firmware for the chip. There is a folder that contains 7 small
> files (on average 70kb) and they end with .bin.fw - I believe that
> these are the files containing assembly code for the chipset. How
> would one go about writing such code from scratch, with only
> general information about the driver? Would it be necessary to have
> technical information such as the number of registers in the
> chipset and eg how they interact? Or Is there a generic codebase of
> 'firmware' that will work with most wifi chipsets? What does the
> firmware actually do?

Normally you don't rewrite firmware (many of the times the source of
firmware are not disclosed by the way).  From the driver standpoint,
firmwares are opaque and hides the detail of underlying hardware,
generally speaking, they simplify or offload the work of the OS driver
and sometimes can workaround bugs of hardware design, etc., and most
firmware are loaded at the time we initialize the hardware.

If you want to redistribute the driver with FreeBSD, vendor permission
will be required.  FreeBSD is flexible wrt firmware, as long as we can
distribute the binary, it's fine.

Of course, it would be nice if the vendor would agree to redistribute
the firmware in source code form, however, they may have reasons to
refuse it and it's not a requirement.

> 2. Source code. This is written in c. At this stage I have no
> questions about it.

Cheers,
- --
Xin LI <[hidden email]>    https://www.delphij.net/
FreeBSD - The Power to Serve!           Live free or die
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (FreeBSD)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQEcBAEBCAAGBQJQEc6uAAoJEG80Jeu8UPuzJfsH+QF2HuvU4Os9tywbl1hdVJb9
vt2crOb1Yv5zX7of2yLpvA2mZsalaeGwj4v7AAsHozBBSy4q/eXy70F74W7O7IGp
ta5+AEYN3lgVNxteIezCxmUu0klKLkoROrxGYKnFW+YK4hjJuwySwDwQv7xTBU4t
cSbe+O3Biqu8sUCawBFHeF9DVUiOQ1AJwSrIIIBHEaCDsYRsg20sXV1PCN0ujR52
mGEa7mA/detiyoDBsBedlFZrDVVC/phkH8qrxfUDiS4/lgzYXXDdBdQ3WUyagdWV
RQmVEowOvlkWqal60EYlFOJMBoNJ+h5GDoIX4YCXAM6O3+X1YLZDKPx2nPMQ9DM=
=T3Z1
-----END PGP SIGNATURE-----
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: TFTPing file from server with Softlink

Dieter BSD
In reply to this post by Ravi Shankar-17
[ posted this a few days ago but it never showed up, trying again... ]

> I am trying to TFTP a file from the server running FreeBSD 6.2
> based OS where the file is a symbolic link to a a file in another
> partition. The TFTP server is failing saying no SUCH FILE
> ( Validate_access fails), but when I copy the file locally, the
> server responds and file is FTPd.

Try "grep ftp /etc/inetd.conf" and see what differences you have
between ftp and tftp. Based on your description of the problem,
I suspect you have a difference in chroot between ftp and tftp.

A different partition can be ok, but must be under the chroot if
you're using chroot.

A symbolic link should be ok, but beware of absolute pathnames
if you're using chroot. If tftp is chroot /foo, an absolute
pathname should leave out the /foo (and thus will not work
without the chroot). Or use a relative pathname. And leave out
the /foo on the machine asking for the file.

Using chroot for tftp is generally a good idea for security reasons.
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
To unsubscribe, send any mail to "[hidden email]"
Loading...