Commit Graph

237590 Commits

Author SHA1 Message Date
uebayasi
593f1cf00f Use "prefix" to specify path out of $S. 2015-09-01 13:46:29 +00:00
tsutsui
6faea00d4b Allow NetBSD/luna68k kernel work with 8kB/page (PGSHIFT==13) settings.
Tested on both LUNA (68030) and LUNA-II (68040).
2015-09-01 13:46:14 +00:00
uebayasi
57eaa88e97 Bump version for "buildprefix". 2015-09-01 13:45:52 +00:00
uebayasi
2cb009cdd9 Introduce a new syntax, "buildprefix", to specify prefix of files under kernel
build subdirectory.  This is not used now that everything is built at the
top of kernel build directory.  It will become mandatory for source/object
files put out of kernel source tree to specify corresponding build subdirectory.
Only ``no dots''  relative path is accepted as "buildprefix".
2015-09-01 13:42:48 +00:00
uebayasi
974426dd69 Keep track of directory of files internally. 2015-09-01 12:46:20 +00:00
uebayasi
3f0546850b Clean up struct files. 2015-09-01 12:32:26 +00:00
uebayasi
3374c75eeb Use per-suffix lists where appropriate. 2015-09-01 12:10:56 +00:00
uebayasi
f5d74fcda3 Abstract struct filetype is no longer needed. 2015-09-01 11:35:46 +00:00
uebayasi
0b130540fb Merge struct objects into struct files. Keep per-suffix file lists. 2015-09-01 11:22:59 +00:00
uebayasi
a0ed6f857a Start merging struct files and struct objects. 2015-09-01 10:37:48 +00:00
ozaki-r
3296ce621c Fix rump.ndp -I options by rump-ifying if_nametoindex(3)
From s-yamaguchi@IIJ
2015-09-01 09:54:34 +00:00
ozaki-r
04bf400967 Move a rtentry definition to reduce its scope
No functional change.
2015-09-01 08:52:02 +00:00
ozaki-r
31cbc4a715 Cleanup nd6_nud_hint
The deleted rtfree was never called.
2015-09-01 08:46:27 +00:00
skrll
047dd37993 Re-apply hunk that got lost in the recent import. CVS is fun! 2015-09-01 06:24:21 +00:00
dholland
ec175d5025 Add new accessors for the d_type and d_namlen fields of struct lfs_direct.
Napalm the old byteswap access logic for these.
2015-09-01 06:16:58 +00:00
dholland
8b103a9c19 Pull over comments on struct direct's type/reclen byte swapping from LFS. 2015-09-01 06:16:03 +00:00
dholland
3911af9340 Comments on directories.
This includes a description of the struct direct byteswap horrors that
ought to be propagated to ufs/ufs.
2015-09-01 06:15:46 +00:00
dholland
5f1180cf85 Remove ulfs_daddr_t. 2015-09-01 06:15:16 +00:00
dholland
08dc10dc96 Use daddr_t, not ulfs_daddr_t, as the latter's 32 bits wide.
Don't use either for on-disk items.
Declare external data in header files.
Part 3 of 3.
2015-09-01 06:15:02 +00:00
dholland
481db95097 Use daddr_t, not ulfs_daddr_t, as the latter's 32 bits wide.
Don't use either for on-disk items.
Part 2 of 3.
2015-09-01 06:13:57 +00:00
dholland
dfb99dfd3e Use daddr_t, not ulfs_daddr_t, as the latter's 32 bits wide.
Don't use either for on-disk items.
Part 1 of 3.
2015-09-01 06:13:33 +00:00
dholland
98320d1917 Fix up indirect block handling in truncate to be 32/64 clean. 2015-09-01 06:13:09 +00:00
dholland
30c3aa6e8a Tidy the MAXSYMLINKLEN macros. 2015-09-01 06:12:33 +00:00
dholland
eb2560adae The ifile's inode number is constant. (it is always 1)
Therefore, storing the value in the superblock and reading it out
again is silly and offers the opportunity for it to become corrupted.
So, don't do that (most of the code already didn't) and use the
existing constant instead. Initialize new 32-bit superblocks with
the value for the sake of old userland programs, but don't keep the
value in the 64-bit superblock at all.

(approved by Margo Seltzer)
2015-09-01 06:12:04 +00:00
dholland
4b344787e1 Make the inode fields in the 64-bit superblock 64 bits wide.
Reasoning as before.

Note that I am not going through and checking for 64->32 truncations
in inode numbers; I'm sure there are quite a few, but that's a project
for later.
2015-09-01 06:11:06 +00:00
dholland
4d398b859d Add byteswapping to the dinode accessors.
This prevents regressions in the ulfs code when switching to the new
accessors. Note that while adding byteswapping to the other accessors
is straightforward, I haven't done it yet; and that also is not enough
to make LFS_EI work, because there are places lying around that bypass
the accessors for one reason and another and all of them need to be
updated. That is going to have to wait for a later day as LFS_EI is
not on the critical path right now.
2015-09-01 06:10:16 +00:00
dholland
d7cf929e20 Propagate fix from lfs:
For non-devices, have getattr (and thus stat) produce NODEV in the
rdev field, instead of leaking the address of the first direct block.
2015-09-01 06:09:23 +00:00
dholland
da32f22c2a Use the lfs dinode accessors in place of the ufs-derived ones.
(Mostly.)

The ufs-derived ones are fake structure member macros, which are gross
and not very safe. Also, it seems that a lot of places in the lfs code
were using the ffsv1 branch of them unconditionally, and this way it's
guaranteed all those places have been updated.

Found while doing this: for non-devices, have getattr produce NODEV
in the rdev field instead of leaking the address of the first direct
block.
2015-09-01 06:08:37 +00:00
ozaki-r
068f46fe61 Define NETHER in rumpkernel
This fixes failures of ATF tests running on rump_server.
2015-09-01 03:26:09 +00:00
pgoyette
06cd199b91 Allow redefinition of options (with only a warning message). Removal
of non-included options was already only a warning.

This also affects redefinition and removal of file-system and makeoption
entries.

Reviewed and OKd by uebayasi@
2015-09-01 01:50:14 +00:00
kamil
596fd5662e Constness correction for the getopt(3) function under REPLACE_GETOPT
Use the __UNCONST() macro, which is used in the other parts for the same
argument nargv, but under the !REPLACE_GETOPT namespace.
2015-09-01 01:28:17 +00:00
uebayasi
5f38d8b6fe Properly handle absolute prefix. 2015-09-01 01:17:56 +00:00
jnemeth
cd3c3a4632 If we're going to note the USSR shooting down civilian airliners,
we should be fair and pick on the USA as well.
2015-09-01 00:56:17 +00:00
uebayasi
4c482b808f Refactor emit file functions. No functional changes. 2015-09-01 00:38:30 +00:00
ozaki-r
13b8e486ae Fix building kernels w/o ether 2015-08-31 16:46:14 +00:00
pooka
1d2b607cca #if __NetBSD__ -> #if defined(__NetBSD__) 2015-08-31 12:57:45 +00:00
pgoyette
b899b8fdca Need to read closer - there was another occurrence of the same tyepo 2015-08-31 12:00:12 +00:00
pgoyette
2ff0a553cb Tyepo 2015-08-31 11:52:37 +00:00
skrll
735145acee Improve error handling in attach code. From t-hash. 2015-08-31 10:41:22 +00:00
christos
bbfa563e5b add missing files 2015-08-31 09:34:07 +00:00
ozaki-r
ac75483513 Fix building kernels w/o DIAGNOSTIC 2015-08-31 09:21:55 +00:00
ozaki-r
0dac802154 Reflect the current ARP cache implementation in tests
net.inet.arp.prune and net.inet.arp.refresh were obsoleted.
2015-08-31 08:08:20 +00:00
ozaki-r
7dc37e542b Remove obsolete global variables and sysctl MIBs 2015-08-31 08:06:30 +00:00
ozaki-r
8997ac8f09 Replace ARP cache (llinfo) with lltable/llentry
Highlights of the change are:
- Use llentry instead of llinfo to manage ARP caches
  - ARP specific data are stored in the hashed list
    of an interface instead of the global list (llinfo_arp)
- Fine-grain locking on llentry
- arptimer (callout) per ARP cache
  - the global timer callout with the big locks can be
    removed (though softnet_lock is still required for now)
- net.inet.arp.prune is now obsoleted
  - it was the interval of the global timer callout
- net.inet.arp.refresh is now obsoleted
  - it was a parameter that prevents expiration of active caches
  - Removed to simplify the timer logic, but we may be able to
    restore the feature if really needed

Proposed on tech-kern and tech-net.
2015-08-31 08:05:20 +00:00
ozaki-r
879526da38 Hook up lltable/llentry with the kernel (and rumpkernel)
It is built and initialized on bootup, but there is no user for now.

Most codes in in.c are imported from FreeBSD as well as lltable/llentry.
2015-08-31 08:02:44 +00:00
martin
cefb36e67b Revert previous, not needed after sys/conf/Makefile.kern.inc rev. 1.215. 2015-08-31 08:00:44 +00:00
ozaki-r
85e26631cc Import lltable/llentry from FreeBSD
lltable/llentry is new L2 nexthop cache data structures that
store caches in each interface (struct ifnet). It is imported
to replace the current ARP cache implementation that uses the
global list with the big kernel lock, and provide fine-grain
locking for cache operations. It is also planned to replace
NDP caches.

The code is based on FreeBSD's lltable/llentry as of r286629
and tweaked for NetBSD.
2015-08-31 07:56:58 +00:00
ozaki-r
730ee823a5 Allow rumpkernel to use rw_obj_* 2015-08-31 07:38:48 +00:00
ozaki-r
3aedc74443 Make rt_refcnt take into account rt_timer 2015-08-31 06:25:15 +00:00
ozaki-r
4e97073b73 Add tests for ICMP redirect timeout 2015-08-31 06:16:08 +00:00