Subject: Linux-Development Digest #809
From: Digestifier <Linux-Development-Request@senator-bedfellow.MIT.EDU>
To: Linux-Development@senator-bedfellow.MIT.EDU
Reply-To: Linux-Development@senator-bedfellow.MIT.EDU
Date:     Thu, 9 Jun 94 09:13:11 EDT

Linux-Development Digest #809, Volume #1          Thu, 9 Jun 94 09:13:11 EDT

Contents:
  Support for Intel Above Board? (Edvard Tuinder)
  Re: where to find the driver for Scanman256 (Karl Eichwalder)
  Re: assembly language & Linux... rep insw, esp. (Vassili Leonov)
  Re: loadable drivers - who played with? (Vassili Leonov)
  Re: My problem? GCC problem? Linux problem? (Andries Brouwer)
  Re: bdflush not running (Tim Cutts)
  Re: Broadcast address on raw sockets return EACCES (Alan Cox)
  where to find the driver for Scanman256 (YEE YUN CHAN)
  Re: Linux game development (Was Re: Why [DOS, W (Elaine Walton)
  Re: NTFS filesystem on disk layout (Dale Shuttleworth)
  Re: My problem? GCC problem? Linux problem? (S. Joel Katz)
  Re: Filesystem semantics protecting meta data ... and users data (Burkhard Neidecker-Lutz)
  Hardware Programing References for a Newbie (Preston William Gilchrist)
  Re: NCR PCI SCSI 53c810 (Kevin Lentin)
  Re: 1.1.17 and no networking won't compile (Rob Janssen)
  Re: Does Linux use any BIOS facilities? (Rob Janssen)
  Re: How access memory from drv? (Rob Janssen)
  Re: bdflush not running (Rob Janssen)
  Re: My problem? GCC problem? Linux problem? (Rob Janssen)
  Re: wfw/lanman/linux interchange? (Byron A Jeff)

----------------------------------------------------------------------------

From: ed@delirium.nl.mugnet.org (Edvard Tuinder)
Subject: Support for Intel Above Board?
Date: 6 Jun 1994 11:42:58 +0200
Reply-To: ed@zoetermeer.nl.mugnet.org (Edvard Tuinder)

Hi,

I recently got a intel above board ISA card and want to use this with my
linux machine. When I install it, linux correctly recognizes the amount
of memory available in the machine (12Mb), but crashes during mem_init....
[ or actually somewhere in _freepages or __get_freepages according to the EIP ]

Does anyone know whether there is support for this card, or if not, has anyone
some pointers as where to start to get this thing going with linux?

System used: I386DX/33 + copro, normally 8Mb linux 1.1.18

Thanx,

Ed
-- 
Edvard Tuinder                                  ed@zoetermeer.nl.mugnet.org

------------------------------

From: karl@pertron.central.de (Karl Eichwalder)
Subject: Re: where to find the driver for Scanman256
Reply-To: keichwa@gwdg.de (Karl Eichwalder)
Date: Wed, 8 Jun 1994 04:59:43 GMT

YEE YUN CHAN (neilsonw@mercury.sfsu.edu) wrote:

tsx-11://../ALPHA/scanner/logiscan.tar.gz

I've got it from a mirror.
--
Karl

------------------------------

From: vassili@cs.sunysb.edu (Vassili Leonov)
Subject: Re: assembly language & Linux... rep insw, esp.
Date: 8 Jun 1994 16:28:44 GMT

Kirk Reiser (kirk@speech.braille.uwo.ca) wrote:
: I was having trouble figuring out the black-art of gcc/gas assembler
Try file tsx-11.mit.edu:/pub/linux/info/gas-doc.tar.Z

------------------------------

From: vassili@cs.sunysb.edu (Vassili Leonov)
Subject: Re: loadable drivers - who played with?
Date: 8 Jun 1994 16:44:41 GMT

$ Burkhard Kohl (buk@taz.de) wrote:
: I played with it about an year ago. Maybe all the people using ftape should 
: have to use modutils.

What is the latest and greatest version of modutils?
I know one dated the the end of year 93 at
tsx-11.mit.edu:/pub/linux/sources/sbin/modutils-0.99.15.tar.gz
is there
 - anything more rescent
 - any other stuff that does the same thing i.e. loadable drivers

Thanks Vassili.

------------------------------

From: aeb@cwi.nl (Andries Brouwer)
Subject: Re: My problem? GCC problem? Linux problem?
Date: Thu, 9 Jun 1994 08:58:30 GMT

ablumer@hubcap.clemson.edu (Aric D. Blumer) writes:

=Given this code:

== void example(s) char *s; {
==      *s = 'h';
== }
== void main() {
==      example("Hello!");
== }

=Should this code cause a Segmentation fault?
=It does running Linux 1.0 and compiled with GCC 2.5.8!
=It doesn't on my Sun.

Compile with -fwritable-strings.

------------------------------

Subject: Re: bdflush not running
From: tjrc1@cus.cam.ac.uk (Tim Cutts)
Date: 9 Jun 1994 08:22:43 GMT

bittner@interaccess (Steve Bittner) writes:

>Does anyone know what 
>       "bdflush not running"
>means?

Precisely what it says.  You're not running bdflush.  Get it from the
same place you got your kernel sources.

Tim.

BTW, isn't this in the FAQ?

------------------------------

Crossposted-To: comp.os.linux.misc,comp.os.linux.help,comp.protocols.tcp-ip
From: iiitac@uk.ac.swan.pyr (Alan Cox)
Subject: Re: Broadcast address on raw sockets return EACCES
Date: Tue, 7 Jun 1994 21:40:44 GMT

In article <2t1avf$8lh@sgi.iunet.it> eb@iunet.it (Enrico Badella) writes:
>When I try to ping from my linux box a broadcast address (193.42.2.255) to
>see what hosts will reply I get the error sendto: permission denied. I looked

Add the lines

        int bcast=1;
        
        setsockopt(socket_fd, SOL_SOCKET,SO_BROADCAST,&bcast,sizeof(bcast));
        
into ping so that it sets the broadcast allowed option.

Alan


------------------------------

From: neilsonw@mercury.sfsu.edu (YEE YUN CHAN)
Subject: where to find the driver for Scanman256
Date: 8 Jun 1994 00:26:47 GMT



------------------------------

From: ewalton@magnus.acs.ohio-state.edu (Elaine Walton)
Subject: Re: Linux game development (Was Re: Why [DOS, W
Date: 8 Jun 1994 00:50:40 GMT

RE: Writing code so that it takes over system to maximize performance.

I was REALLY surprised so this.  Certainly it may be a concern to get
performance from some of the older machines, but with effective use of
code design _almost_never_requires_assembler_coding_.  Some have claimed
that they can get much better performance out of assembler than a third-
generation language like C or Pascal.  I have to agree with them--if they
are talking about <10000 assembler-lines.  Studies have indicated that
the 10000 assembler-line limit is about as much as a project can handle
without significant overhead.  Now, I want you to know that these same
studies indicate that there are 5-25 assembler-lines per 1 line high-
level language.  That translates to around 400-2000 lines of C!  That's
not enough for a good-sized program!
Here is a part of a long list of rules of thumb for fast programs 
(currently unordered):

     -Start with a very good data design.  Figure out what needs to be
      calculated at runtime--minimize them!  Do as much as possible
      before anything runs (like backdrops, static graphics, lookup
      tables, etc.)
     -Generally speaking, multiplies and divides are still expensive.
      Take advantage of bit shifting, masking, ANDing and ORing.
     -Floating point is expensive.  With ingenuity, you can simulate
      limited floating point with longs.
     -Abstract operations.  One routine typically can supply tools for
      several needs.  For example, version 11 of Unix had 5-6 implement-
      ations of "queue".  What a waste!
     -Use a good profiler to find "hot spots" in your code.  These will
      need a little more tweeking.
     -Limit the number of parameters passed to no more than three (four?).
      Any time you have more than three parameters, you increase the time
      setting up for a call and decrease comprehensibility (thus
      maintainability).
     -NO GLOBAL VARIABLES.  This is the one problem that makes large
      program developer lose his/her hair.  It is better to pass what
      you need through parameters than sacrifice trackability and
      maintainability.
     -Any global variables should be encompassed by read/write/modify
      routines or be read-only (CONST).
     -Don't pass whole structures or records--pass pointers to them
      instead.
-Sean

------------------------------

From: dale@mipc-03.brunel.ac.uk (Dale Shuttleworth)
Subject: Re: NTFS filesystem on disk layout
Reply-To: ee90dcs@brunel.ac.uk
Date: Wed, 8 Jun 1994 00:39:10 GMT

Mikael Nykvist (viper@ludd.luth.se) wrote:
: In <TVO.94Jun5182603@zaphod.swb.de> tvo@zaphod.swb.de (Thomas Vogler) writes:

: >i intend to write a filesystem driver for linux supporting NTFS in order
: >to be able to access my NTFS formatted disks under Linux. In a first
: >attempt i plan to support read only access only, write access might follow
: >later.

: >in order to do this, i will need some informations how NTFS files are stored
: >on a disk.

: >does anyone know a source of information where such details can be found ?

: Because of the B2 (or was it C2 ?...) security, I dont think MS will release
: any 'internal' info about NTFS... If they did, you could make a boot-disk
: that could access the NTFS-partions and the security are lost..

Surely not.  I cannot imagine that the obscurity or otherwise of a file
system would have any impact on the security rating a system would
achieve.  MS may not release info for reasons other than security.  They
would be shooting themselves in the foot if they suggested that their
file system was so insecure that mere knowledge of how it works would
allow you to break it.

                Dale.
--
******************************************************************************
*  Dale Shuttleworth                                                         *
*  Dept of Elec Eng,  Brunel University, Uxbridge, UB8 3PH, UK               *
*  ee90dcs@brunel.ac.uk                                                      *
******************************************************************************

------------------------------

From: stimpson@panix.com (S. Joel Katz)
Subject: Re: My problem? GCC problem? Linux problem?
Date: 9 Jun 1994 04:27:34 -0400

In <2t6di5$f1d@nwfocus.wa.com> ken@chinook.halcyon.com (Ken Pizzini) writes:

>In article <ablumer.771128485@hubcap>,
>Aric D. Blumer <ablumer@hubcap.clemson.edu> wrote:
>>Given this code:
>>
>>> void example(s)
>>> char *s;
>>> {
>>>     *s = 'h';
>>>     }
>>> void main()
>>> {
>>>     example("Hello!");
>>>     }
>>
>>Should this code cause a Segmentation fault?
>>It does running Linux 1.0 and compiled with GCC 2.5.8!
>>It doesn't on my Sun.

>Let's put it diplomatically: it is permitted to blow up.
>ANSI says that the string constant in your code may be placed
>in read-only memory.  Gcc, by default, does.

        Text between quotes is a string _constant_. In C++, the address 
of a constant should only be put in a const pointer. In C, if the address 
of a constant is put into a pointer, no attempt to derefernce the pointer 
as an lvalue should be attempted.

        You have broken the rules.

        SJK
 

------------------------------

From: neideck@nestvx.enet.dec.com (Burkhard Neidecker-Lutz)
Crossposted-To: comp.benchmarks,comp.sys.sun.admin,comp.security.unix
Subject: Re: Filesystem semantics protecting meta data ... and users data
Date: 9 Jun 1994 11:26:05 GMT

In article <DHOLLAND.94Jun8134511@husc7.harvard.edu> dholland@husc7.harvard.edu (David Holland) writes:
>
>This is how it happens, as the original poster presented it:

NOT
>
>               file Y is deleted --->

so blocks are being released, causing metadata to be updated *on disk*
before any other file gets a chance of reusing that block.

>                                       <--- file X is written, using
>                                            blocks formerly from file Y

Which are zero-filled at that time.

>       file Y's inode is written --->

Can't happen now (after all, Y was deleted and hence it's inode
is *gone*). Even if Y was truncated by ftruncate(2), that would have
been noted on disk *before* the blocks could be gotten at from
X.

>                                       <--- file X's inode is written
>                                  <CRASH>
>                                       <--- file X's data was never written
>
>Now, after recovery and reboot, file X contains some blocks that used
>to be in file Y... which still contain the data from file Y.
>
>Security breach.

Maybe on UNIX V6 15 years ago.

>I don't know if this is actually possible with current filesystems;
>I'd hope not, but...

Can't speak for SUN :-), but can't happen on any modern UNIX I know.

                Burkhard Neidecker-Lutz

Distributed Multimedia Group, CEC Karlsruhe 
Advanced Technology Group, Digital Equipment Corporation
neideck@nestvx.enet.dec.com

------------------------------

From: pwg7503@tamsun.tamu.edu (Preston William Gilchrist)
Subject: Hardware Programing References for a Newbie
Date: 7 Jun 1994 20:16:45 -0500

I am a farely experience C programmer but have done little programming that
has dealt with lower level hardware access(ie. disks, cdroms, sound cards, etc)
I was wondering if anyone can recommend a good reference source for access to
these types of hardware items, command codes used, and standards for hardware
items such as SCSI cards, sound cards, and such.  I would like as much linux
specific docs as possible but any PC related stuff appreciated.  

Preston Gilchrist
Please Respond via E-Mail : pwg7503@tamsun.tamu.edu



------------------------------

From: kevinl@bruce.cs.monash.edu.au (Kevin Lentin)
Subject: Re: NCR PCI SCSI 53c810
Date: 9 Jun 1994 11:26:29 GMT

Evmorfopoulos Dimitris (devmorfo@mtu.edu) wrote:

>       I have a question for everyone. Is there anybody that knows what happened 
> to Drew Eckhardt (drew@kinglear.cs.Colorado.EDU), who was developping the driver
> for the NCR PCI SCSI 53c810 ? I tryied contacting him, and the first time I got
> now reply, where the rest of the times, my mail jus tbounced back at me. Is 
> anybody besides Drew that works on that ?

I got a mail reply from him yesterday (I was about to mail him something
else now). A little investigating shows that he was logged onto kinglear
about 3 hours ago.

-- 
[==================================================================]
[ Kevin Lentin                   |___/~\__/~\___/~~~~\__/~\__/~\_| ]
[ kevinl@bruce.cs.monash.edu.au  |___/~\/~\_____/~\______/~\/~\__| ]
[ Macintrash: 'Just say NO!'     |___/~\__/~\___/~~~~\____/~~\___| ]
[==================================================================]

------------------------------

From: rob@pe1chl.ampr.org (Rob Janssen)
Subject: Re: 1.1.17 and no networking won't compile
Reply-To: pe1chl@rabo.nl
Date: Thu, 9 Jun 1994 07:45:13 GMT

In <hamilton.771088043@kickapoo> hamilton@cs.iastate.edu (Jon Hamilton) writes:

>>I also have problems with files not being found during a compile. At first
>>I thought that the distributions may have been deficient... but after reading
>>the above posts I'm not so sure. My compile problems have been so serious
>>that I have taken to finding binary releases for everything that I want as
>>I can build almost nothing that will finish making.

>Which files aren't being found?  You need a fairly recent libc and gcc
>for newer kernels; sounds like your gcc is either out of date or 
>improperly installed.  

Often the /usr/include/linux and /usr/include/asm symlinks are wrong or
aren't even symlinks at all on binary-only installations.  That can cause
some interesting problems as well :-)

Rob
-- 
=========================================================================
| Rob Janssen                | AMPRnet:   rob@pe1chl.ampr.org           |
| e-mail: pe1chl@rabo.nl     | AX.25 BBS: PE1CHL@PI8UTR.#UTR.NLD.EU     |
=========================================================================

------------------------------

From: rob@pe1chl.ampr.org (Rob Janssen)
Subject: Re: Does Linux use any BIOS facilities?
Reply-To: pe1chl@rabo.nl
Date: Thu, 9 Jun 1994 07:50:05 GMT

In <1994Jun8.160547.10423@ll.mit.edu> kpl@ll.mit.edu (Kevin P. Lawton) writes:

>I'm curious if Linux uses any of the ROM BIOS facilities
>which are inherent to the PC, or if it exclusively uses
>its own facilities which are loaded upon booting.

Linux does not use the ROM BIOS, because it is unusable in a 32-bit
protected mode environment.  So, it uses its own drivers that directly
control the hardware.

dosemu can use the VGA BIOS from its virtual machine, but this is not
a generic way to call ROM BIOS code.  it could be done in a similar way
from Linux, but it is generally agreed to be inefficient.

Rob
-- 
=========================================================================
| Rob Janssen                | AMPRnet:   rob@pe1chl.ampr.org           |
| e-mail: pe1chl@rabo.nl     | AX.25 BBS: PE1CHL@PI8UTR.#UTR.NLD.EU     |
=========================================================================

------------------------------

From: rob@pe1chl.ampr.org (Rob Janssen)
Subject: Re: How access memory from drv?
Reply-To: pe1chl@rabo.nl
Date: Thu, 9 Jun 1994 07:54:31 GMT

In <2t4tfo$qiv@newsserv.cs.sunysb.edu> vassili@cs.sunysb.edu (Vassili Leonov) writes:

>I was writing a driver for PRI48 T1 interface card and due to my
>limited experience with that in Un*x environment - how
>do I address physical memory from withing the driver code?

>If you do it from the process then you use the mmap with "/dev/mem"
>driver to set the mapping - this is WRONG to do from the driver.

>Am I correct, that from the driver logical addresses are equal to
>physical - at least within the 1st Meg - i.e. if I want to address
>something at the base address 0xd0000 I just say:

>char * ph_mem;

>(long) ph_mem = 0xd0000;

>&ph_mem = 123;

Yes.  All memory is identity-mapped in the kernel.

You can see direct memory accesses in other drivers as well, e.g. to
look in onboard BIOS roms for signatures...

Rob
-- 
=========================================================================
| Rob Janssen                | AMPRnet:   rob@pe1chl.ampr.org           |
| e-mail: pe1chl@rabo.nl     | AX.25 BBS: PE1CHL@PI8UTR.#UTR.NLD.EU     |
=========================================================================

------------------------------

From: rob@pe1chl.ampr.org (Rob Janssen)
Subject: Re: bdflush not running
Reply-To: pe1chl@rabo.nl
Date: Thu, 9 Jun 1994 08:00:41 GMT

In <2t5ens$86o@mailhost.interaccess.com> bittner@interaccess (Steve Bittner) writes:

>Does anyone know what 
>       "bdflush not running"
>means?

It means that you installed a new kernel without getting and installing
bdflush.

Rob
-- 
=========================================================================
| Rob Janssen                | AMPRnet:   rob@pe1chl.ampr.org           |
| e-mail: pe1chl@rabo.nl     | AX.25 BBS: PE1CHL@PI8UTR.#UTR.NLD.EU     |
=========================================================================

------------------------------

From: rob@pe1chl.ampr.org (Rob Janssen)
Subject: Re: My problem? GCC problem? Linux problem?
Reply-To: pe1chl@rabo.nl
Date: Thu, 9 Jun 1994 08:07:43 GMT

In <ablumer.771128485@hubcap> ablumer@hubcap.clemson.edu (Aric D. Blumer) writes:

>Given this code:

>> void example(s)
>> char *s;
>> {
>>      *s = 'h';
>>      }
>> void main()
>> {
>>      example("Hello!");
>>      }

>Should this code cause a Segmentation fault?
>It does running Linux 1.0 and compiled with GCC 2.5.8!
>It doesn't on my Sun.


>I'm porting some code that does something similar and
>it always faults.

Read the gcc documentation about 'writable strings'.
The behaviour of the above code depends on the compilation flags you
pass to gcc.  In some (many) situations it will place the strings in
write-protected memory, and you will get this fault.  The -traditional
and -fwritable-strings options affect this behaviour.

If it is not too much work, modify your source.  Things like done in
your example are ugly, IMHO.  That it works on a Sun is no excuse...

Rob
-- 
=========================================================================
| Rob Janssen                | AMPRnet:   rob@pe1chl.ampr.org           |
| e-mail: pe1chl@rabo.nl     | AX.25 BBS: PE1CHL@PI8UTR.#UTR.NLD.EU     |
=========================================================================

------------------------------

From: byron@cc.gatech.edu (Byron A Jeff)
Subject: Re: wfw/lanman/linux interchange?
Date: 9 Jun 1994 07:57:45 -0400

[Check the Subject for what Lars wanted to know]

Lars, here's what you're looking for.
This info was posted to c.o.l.a about 3 months ago.

                Announcing SMBServer version 1.6
                ================================

What is SMBServer?
==================

SMBServer is a unix based SMB file server. This allows a unix host to
act as a file and print server for SMB clients. This includes
Lan-Manager compatible clients such as LanManager for DOS, Windows for
Workgroups, Windows NT, OS/2, Pathworks and many more.

The package also includes a unix SMB client and a netbios nameserver.

What can it do for me?
======================

If you have any PCs running SMB clients, such as a PC running Windows
for Workgroups, then you can mount file space or printers from a unix
host, so that directories and files on the unix host are available on the PC.

The client part of the package will also allow you to attach to other
SMB servers (such as windows NT and windows for workgroups 3.11) so
that you can copy files to and from your unix host. The client also
allows you to access a SMB printer (such as one attached to an OS/2 or
WfWg server) from Unix, using an entry in /etc/printcap, or by
explicitly specifying the command used to print files.

What are it's limitations?
==========================

Currently the server completely supports up to the CORE+ level of the
SMB protocol. This allows you to do all the normal file and print
operations from a PC. Work is nearly complete on the LANMAN1.0
protocol level which will add some new features. Following this work
will begin on supporting the LANMAN2.1 level. The main thing this will
gain is long filenames for clients that support them (such as Windows
NT).

The protocol includes a negotiation phase, and all clients should
support working with the CORE+ protocol (or a lower protocol), so the
transition from one protocol level to another is transparent for most
users.

What are it's features?
========================

SMBServer supports many features that are not supported in other SMB
implementations (all of which are commercial). Some of it's features
include host as well as username/password security, a unix client,
automatic home directory exporting, automatic printer exporting, dead
connecton timeouts, umask support, guest connections and hidden and
system attribute mapping. Look at the man pages included with the
package for a full list of features.

Where can I get a client for my PC?
===================================

There is a free client for MS-DOS based PCs available from
ftp.microsoft.com in the directory Advsys/MSclient/. Please read the
licensing information before downloading. The Windows for Workgroups
client is also very good.

What network protocols are supported?
=====================================

Currently only TCP/IP is supported. One person has used the server
with Decnet but the patches are not yet available. As most clients
come with a TCP/IP option it is unlikely that SMBServer will have
support for other protocols in the near future.

How much does it cost?
======================

SMBServer software is free software. It is available under the
GNU Public license in source code form at no cost. Please read the
file COPYING that comes with the package for more information.

What flavours of unix does it support?
=======================================

The code has been written to be as portable as possible. It has been
"ported" to many unixes, which mostly required changing only a few
lines of code. It has been run (to my knowledge) on these unixes:

Linux, SunOS, Solaris, SVR4, Ultrix, OSF1 (Alpha), AIX, BSDI, NetBSD, Sequent,
HP-UX, SGI, FreeBSD, and NeXT.

Some of these have received more testing than others. If it doesn't
work with your unix then it should be easy to fix.

Why version 1.6?
================

This may be the first time you have heard of this software, because it
hasn't been widely advertsed before. Please look at the file
`history' in the distribution for a brief deease look at the file
`history' in the distribution for a brief description of the
development of the software.

Who wrote it?
=============

Many people on the internet have contributed to the development of
SMBserver. The maintainer and original author is Andrew Tridgell, but
large parts of the package were contributed by several people from all
over the world. Please look at the file `change-log' for information
on who did what bits.

Where can I get it?
===================

The package is available via anonymous ftp from nimbus.anu.edu.au in
the directory pub/tridge/server/. The tarred/ subdirectory contains
archived copies of the complete package.

Where can I get more info?
===========================

Please join the mailing list for the software if you want to discuss
the development or use of SMBserver. To join the mailing list send
mail to lists@arvidsjaur.anu.edu.au with a body of "subscribe netbios".



Andrew Tridgell (Andrew.Tridgell@anu.edu.au)
March 1994
-- 
---
Another random extraction from the mental bit stream of...
Byron A. Jeff - PhD student operating in parallel - And Using Linux!
Georgia Tech, Atlanta GA 30332   Internet: byron@cc.gatech.edu

------------------------------


** FOR YOUR REFERENCE **

The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:

    Internet: Linux-Development-Request@NEWS-DIGESTS.MIT.EDU

You can send mail to the entire list (and comp.os.linux.development) via:

    Internet: Linux-Development@NEWS-DIGESTS.MIT.EDU

Linux may be obtained via one of these FTP sites:
    nic.funet.fi				pub/OS/Linux
    tsx-11.mit.edu				pub/linux
    sunsite.unc.edu				pub/Linux

End of Linux-Development Digest
******************************
