Commit graph

715 commits

Author SHA1 Message Date
Thomas Veerman
39dfb2bc55 Don't build ext2 ramdisk for cross compilation
. as mkfs.mfs is now cross compilable, we can remove the ext2 ramdisk
  special case for cross compilation.
2012-06-18 10:54:56 +00:00
Thomas Veerman
aab6eb7615 Clean up generated files for ash,ramdisk,libutil,libc 2012-06-18 10:54:56 +00:00
Thomas Veerman
791aa4e16f Cross compile MFS ramdisk 2012-06-18 10:54:55 +00:00
Thomas Veerman
03ea1c1676 Dynamically determine which ramdisk to use
.Also, rename ext2_ramdisk to ramdisk_ext2.
2012-06-18 10:53:36 +00:00
Thomas Veerman
f09c2e014f Use MACHINE_ARCH instead of ARCH 2012-06-18 10:53:35 +00:00
Thomas Veerman
f93afa00e9 Remove MINIXSRCDIR and use NETBSDSRCDIR
NETBSDSRCDIR is used all over the place anyway, and this reduces
our diff with NetBSD a little.
2012-06-18 10:53:35 +00:00
Thomas Veerman
d1301b26b3 Use buildsystem commands instead of {cp,mkdir} 2012-06-18 10:53:33 +00:00
Thomas Veerman
acac1f2fda Cross-compilation fixes
. Some Makefile fixes to automatically differentiate between a normal
  compilation and cross-compilation. Also, build compressed images.
. Harmonize ramdisk rc scripts for normal use case and ext2 ramdisk.
. ext2_ramdisk filesystem prototype fixes.
2012-06-18 10:53:32 +00:00
Thomas Veerman
0bcc4c15c9 newroot is gone too 2012-06-18 10:53:31 +00:00
Thomas Veerman
d0c7c2a5d2 bios_wini is no longer amongst us 2012-06-18 10:53:31 +00:00
Dirk Vogt
67ff0d71ed ext2 ramdisk: copy rc to correct destination 2012-06-18 10:53:28 +00:00
Dirk Vogt
56f6a77ead ramdisk: don't do anything at dependall 2012-06-18 10:53:27 +00:00
Dirk Vogt
ed4df03113 Include ext2 ramdisk in build and remove sync
As the ramdisk and ext2 ramdisk don't build anything for the install
and all targets, memory does not have to wait for them anymore.
2012-06-18 10:53:26 +00:00
Dirk Vogt
bfacef76c5 Add ext2 ramdisk, intended for cross compilation 2012-06-18 10:53:25 +00:00
Dirk Vogt
a8f6f3ebc9 Make ramdisk location configurable
Also, the ramdisk is now built when the memory driver is compiled.
2012-06-18 10:53:25 +00:00
Dirk Vogt
c2c39af6bb Make TTY cross-compilable 2012-06-18 10:53:23 +00:00
Ben Gras
2bfeeed885 drop segment from safecopy invocations
. all invocations were S or D, so can safely be dropped
	  to prepare for the segmentless world
	. still assign D to the SCP_SEG field in the message
	  to make previous kernels usable
2012-06-16 16:22:51 +00:00
Ben Gras
73379f0be5 set major version of shlibs to 0
WARNING: this will break existing dynamically linked binaries if they
exist. If you have any:
	. re-build world statically first if necessary
	. remove libraries from /lib and /usr/lib
	. then build world

This change:
	. avoids possible future dismay when interfacing other
	  systems' binaries; done until they are abi-compatible

Thanks to Antoine Leca for pointing this out.
2012-05-10 16:38:24 +02:00
Ben Gras
cfb2d7bca5 retire BIOS_SEG and umap_bios
. readbios call is now a physical copy with range check in
	  the kernel call instead of BIOS_SEG+umap_bios
	. requires all access to physical memory in bios range to go
	  through sys_readbios
	. drivers/dpeth: wasn't using it
	. adjusted printer
2012-05-09 19:03:59 +02:00
Ben Gras
b611e4c226 brazilian keymap
contributed by David Augusto.
2012-05-04 13:56:04 +02:00
Ben Gras
b332803b6f release fixes
. make ramdisk buildable without ../etc having pwd.db
	. add cat to release bootstrap cmds
	. support running dynamically linked executables for
	  release bootstrap cmds
	. import netbsd chroot to help
2012-04-17 16:58:58 +02:00
Ben Gras
53f94f8ed4 dynamic executables on ramdisk support
See UPDATING about upgrading clang for dynamic linking.

	. allow executables on ramdisk to be dynamically linked; this means
	  putting a few required shared libraries and ld.elf_so on the ramdisk.
	. this makes the ramdisk (usage) smaller when they are dynamic, but
	  bigger when they're not.
	. also we can safely ditch newroot and call mount directly as that is
	  all newroot does.
	. create proto.common to share a bunch of entries between
	  small/nonsmall cases
2012-04-16 14:06:09 +02:00
Ben Gras
4b999f1962 build shared versions of libraries
building defaults to off until clang is updated.

current clang does not handle -shared, necessary to change the ld
invocation to build shared libraries properly. a new clang should be
installed and MKPIC defaults to no unless the newer clang is detected.

changes:

	. mainly small imports of a Makefile or two and small fixes
	  (turning things back on that were turned off in Makefiles)
	. e.g.: dynamic librefuse now depends on dynamic
	  libpuffs, so libpuffs has to be built dynamically too
	  and a make dependency barrier is needed in lib/Makefile
	. all library objects now have a PIC (for .so) and non-PIC
	  version, so everything is built twice.
	. generate PIC versions of the compat (un-RENAMEd) jump files,
	  include function type annotation in generated assembly
	. build progs with -static by default for now
	. also build ld.elf_so
	. also import NetBSD ldd
2012-04-16 05:21:20 +02:00
Thomas Veerman
ca7a466f48 TTY: don't allow multiple readers on tty minor
TTY has no way of keeping track of multiple readers for a tty minor
device. Instead, it stores a read request for the last reader only.
Consequently, the first ("overwritten") reader gets stuck on a read
request that's never going to be finished. Also, the overwriting
causes a grant mismatch in VFS when TTY returns a reply for the
second reader.

This patch is a work around for the actual problem (i.e., keeping track
of multiple readers). It checks whether there is a read operation in
progress and returns an error if it is --preventing that reader from
getting overwritten and stuck. It fixes a bug triggered by executing
'top | more' and pressing the space bar for a while (easily reproducable
in a VM, not on hardware).
2012-04-13 13:22:13 +00:00
Ben Gras
511c977f93 retire bios_wini 2012-04-12 03:02:21 +02:00
David van Moolenbroek
6aa61efd09 VBOX: add host/guest communication interface
This interface can be used by other system processes by means of the
newly provided vbox API in libsys.
2012-04-09 15:56:20 +02:00
David van Moolenbroek
fa805ebd1e Kernel/servers/drivers: resolve a few warnings
Flagged by clang 3.1.
2012-03-30 16:55:06 +02:00
Ben Gras
7336a67dfe retire PUBLIC, PRIVATE and FORWARD 2012-03-25 21:58:14 +02:00
Ben Gras
6a73e85ad1 retire _PROTOTYPE
. only good for obsolete K&R support
	. also remove a stray ansi.h and the proto cmd
2012-03-25 16:17:10 +02:00
David van Moolenbroek
186a4db672 ahci: use sys_vumap() instead of sys_umap()
This is only an optimization for CPU performance. Callers are
currently still required to supply contiguous memory.
2012-03-24 19:51:13 +01:00
David van Moolenbroek
e8d2d2f6b6 libminc-related updates
- add files needed for acpi, ahci, fbd, vfs to libminc
- remove "-lc" from their respective makefiles
- remove setenv from libminc (requires initialization)
2012-03-12 23:16:45 +01:00
David van Moolenbroek
457d3884a2 pci: apply ACLs to device reservations 2012-03-08 23:52:17 +01:00
David van Moolenbroek
e21c21a31a pci: USER_SPACE cleanup 2012-03-08 23:52:13 +01:00
David van Moolenbroek
291ece0caa drivers: slightly better use of PCI constants
- introduce PCI_BAR_{IO|MEM}_MASK
- remove redundant PCI definitions from lance
- fix vbox BAR retrieval
2012-03-08 23:51:18 +01:00
David van Moolenbroek
5152cfd8bd drivers: remove redundant PCI ID tables
- remove PCI tables where system.conf suffices
- remove drivers' ability to mess up NIC order
- fix dp8390 PCI enumeration
- convert ti1225 to instance model
- add system.conf entry for ti1225
2012-03-07 23:58:00 +01:00
David van Moolenbroek
de45264c74 dp8390,ti1225: reenable register memory mapping 2012-03-07 23:57:34 +01:00
David van Moolenbroek
21ed531c8f pci: remove pci_init1 API call 2012-03-07 23:56:08 +01:00
David van Moolenbroek
ca95f69f25 drivers: resolve compiler warnings 2012-03-05 22:32:55 +01:00
David van Moolenbroek
831450aacc e1000: add support for 82545EM
Tested on VirtualBox and VMware.
2012-03-05 13:00:06 +01:00
Tomas Hruby
72b7abd1a1 VFS - no CANCEL for async non-blocking operations
- if an operation (R, W, IOCTL) is non blocking, a flag is set
  and sent to the device.

- nothing changes for sync devices

- asyn devices should reply asap if an operation is non-blocking.
  We must trust the devices, but we had to trust them anyway to
  reply to CANCEL correctly

- we safe sending CANCEL commands to asyn devices. This greatly
  simplifies the protocol. Asynchronous devices can always reply
  when a reply is ready and do not need to deal with other
  situations

- currently, none of our drivers use the flags since they drive
  virtual devices which do not block
2012-03-02 15:44:48 +00:00
Ben Gras
25fae1d7da portugese keymap
contributed by ralxc
2012-02-18 02:05:04 +01:00
Antoine Leca
ab0a67f7af Use objcopy to build ramdisk object
. during build, uses much less memory,
	  disk space, and time
	. lets us throw out bintoc
2012-02-17 12:56:38 +00:00
Arun Thomas
ff56906879 Remove obsolete INSTALLFLAGS from makefiles 2012-02-16 23:26:38 +01:00
Thomas Veerman
0491126758 Don't update mtab upon mounting procfs
It causes an ugly error message when booting from cd and it gets
overwritten by `printroot >/etc/mtab` in /etc/rc anyway.
2012-02-14 17:23:36 +00:00
Ben Gras
2fe8fb192f Full switch to clang/ELF. Drop ack. Simplify.
There is important information about booting non-ack images in
docs/UPDATING. ack/aout-format images can't be built any more, and
booting clang/ELF-format ones is a little different. Updating to the
new boot monitor is recommended.

Changes in this commit:

	. drop boot monitor -> allowing dropping ack support
	. facility to copy ELF boot files to /boot so that old boot monitor
	  can still boot fairly easily, see UPDATING
	. no more ack-format libraries -> single-case libraries
	. some cleanup of OBJECT_FMT, COMPILER_TYPE, etc cases
	. drop several ack toolchain commands, but not all support
	  commands (e.g. aal is gone but acksize is not yet).
	. a few libc files moved to netbsd libc dir
	. new /bin/date as minix date used code in libc/
	. test compile fix
	. harmonize includes
	. /usr/lib is no longer special: without ack, /usr/lib plays no
	  kind of special bootstrapping role any more and bootstrapping
	  is done exclusively through packages, so releases depend even
	  less on the state of the machine making them now.
	. rename nbsd_lib* to lib*
	. reduce mtree
2012-02-14 14:52:02 +01:00
Evgeniy Ivanov
3dd49be938 Allow human readable name for the root device.
Instead of using rootdev= or ramimagedev= in the boot monitor
which are changed to numbers and cannot be used with other
loaders, rootdevname= or ramimagename= are (MINIX-style)
device names always stored as strings.

Patch by Antoine Leca.
2012-02-09 18:54:45 +01:00
Ben Gras
cc1ae59c9b -lminixutil link fixes
. not available and not needed for clang
2012-02-06 16:08:29 +01:00
Evgeniy Ivanov
65f97ea344 Enlarge ramdisk size (blocks). 2012-02-06 16:07:55 +01:00
Thomas Veerman
d5210e9bdd e1000: reset hardware before stopping 2012-01-30 16:47:11 +00:00
Erik van der Kouwe
4bee3cff2e Prevent the ramdisk makefile from failing if the last image is not ELF 2012-01-27 13:10:00 +01:00