Age | Commit message (Collapse) | Author |
|
2001-01-07 Marcus Brinkmann <marcus@gnu.org>
* hurd.texi (Diskfs Callbacks): Make diskfs_dirstat_size const.
ext2fs/
2001-01-07 Marcus Brinkmann <marcus@gnu.org>
* dir.c: Make diskfs_dirstat_size const.
isofs/
2001-01-07 Marcus Brinkmann <marcus@gnu.org>
* lookup.c: Make diskfs_dirstat_size const.
ufs/
2001-01-07 Marcus Brinkmann <marcus@gnu.org>
* dir.c: Make diskfs_dirstat_size const.
libdiskfs/
2001-01-07 Marcus Brinkmann <marcus@gnu.org>
* diskfs.h: Make diskfs_dirstat_size const.
libdiskfs/
2001-01-07 Marcus Brinkmann <marcus@gnu.org>
* file-statfs.c: Include <string.h>.
ftpfs/
2001-01-07 Marcus Brinkmann <marcus@gnu.org>
* dir.c (ftpfs_dir_create): Fix last change (calloc invocation).
2001-01-07 Marcus Brinkmann <marcus@gnu.org>
* copy.c: Include <mach.h>. New macro page_aligned.
(copy_write): Cast buf to vm_address_t in call to vm_write.
Dereference amount for memcpy.
(copy_read): Add len parameter to vm_read, remove redundant following
len assignment.
|
|
* rr.c (rrip_work): Use strdup instead malloc and strcpy.
Assert that strdup and malloc (for rr->trans) succeeds.
* pager.c: Include <errno.h>.
(create_disk_pager): If malloc fails, exit with error.
* main.c (read_sblock): Fail if malloc does.
* inode.c (diskfs_cached_lookup): When allocating memory for dn or
np fails, release spinlock, rrip (and allocated memory) and return
ENOMEM.
(load_inode): Likewise (but no rrip). Also, if *npp is non-zero,
release diskfs_node_refcnt_lock before returning.
Reported by Igor Khavkine <i_khavki@alcor.concordia.ca>.
|
|
* init.c (process_rc_script): If malloc fails, return ENOMEM.
Reported by Igor Khavkine <i_khavki@alcor.concordia.ca>.
|
|
* dir.c (ftpfs_dir_create): New macro INIT_HTABLE_LEN to
specify initialize htable_len. New variable htable,
allocate memory to it with calloc before acquiring a node
reference. If this fails, return any allocated memory and
return with ENOMEM. Set new->htable_len to INIT_HTABLE_LEN
and new->htable to htable. Don't bzero htable anymore, as
we use calloc.
|
|
* pager.c: Include <errno.h>.
(create_disk_pager): Panic if malloc fails.
Reported by Igor Khavkine <i_khavki@alcor.concordia.ca>.
* inode.c (diskfs_get_translator): If malloc fails, set err to ENOMEM.
Initialize err with 0, and return it at the end of the function.
Reported by Igor Khavkine <i_khavki@alcor.concordia.ca>.
|
|
* boot.c (main): If malloc or realloc fails, print diagnostic
message and exit.
(queue_read): Change return type from void to kern_return_t.
If malloc fails, return D_NO_MEMORY, otherwise D_SUCCESS (to simplify
code flow, malloc before acquiring the queuelock).
(ds_device_read): New variable err (local to the block in which it is used).
If queue_read fails, pass through error.
(ds_device_read_inband): Likewise.
(S_io_read): Likewise.
Reported by Igor Khavkine <i_khavki@alcor.concordia.ca>.
|
|
|
|
* options.c (parse_opt): Set err to 0 if it was ESRCH.
(or zero after anyway).
|
|
2000-12-30 Marcus Brinkmann <marcus@gnu.org>
* netfs.h: Revert doc "fix" of netfs_attempt_chmod.
|
|
* netfs.h: Merge Neals words into documentation of netfs_nput,
netfs_nrele, netfs_nref.
|
|
* dir.c: Include <stddef.h>, <unistd.h>, <sys/mman.h>
(diskfs_get_directs): Cast *data to struct dirent *.
* node.c: Include <stddef.h>.
(diskfs_alloc_node): Remove unused variables err, st, np.
(diskfs_free_node): Use *np->dn, not *dn to calculate used space.
(recompute_blocks): Replace DT_DEV with DT_BLK.
(diskfs_node_norefs): Likewise.
(recompute_blocks): Take address of np->dn_stat for pointer st.
(diskfs_cached_lookup): New variable st.
(diskfs_cached_lookup): Set st to &np->dn_stat, not &dn->dn_stat.
(create_symlink_hook): Fix malloc call and return code check.
(read_symlink_hook): Return 0.
* tmpfs.c: Include <argp.h>, <string.h>, <inttypes.h>, <argz.h>,
<error.h>.
(parse_opt): Reverse second and third argument of strtoimax call.
* tmpfs.h (struct disknode): Remove blind passenger (unnamed copy
of anonymous struct {} reg).
Some of the above were also reported by Alexey Dejneka
<adejneka@comail.ru>.
|
|
|
|
* netfs.h (struct node): Adjust comment fixes by last change
to be more in line with similar comments elsewhere.
* make-node.c (netfs_make_node): Return 0 if malloc does.
Reported by Neal H Walfield <neal@cs.uml.edu>.
2000-12-29 Neal H Walfield <neal@cs.uml.edu>
* dir-lookup.c (netfs_S_dir_lookup): Do not bother zeroing np, it
happens later anyway. Replace bcopy with memcpy.
* file-get-translator.c (netfs_S_file_get_translator): Replace
bcopy with memcpy.
* io-seek.c (netfs_S_io_seek): Only get the lock if we need it.
* io-stat.c (netfs_S_io_stat): Replace bcopy with memcpy.
* io-write.c (netfs_S_io_write): Wait until the lock is needed.
* netfs.h: Complete documentation revision. The locking protocol
is now very explicit.
* nput.c (netfs_nput): Added comment.
* nrele.c (netfs_nrele): Likewise.
* set-get-trans.c: Likewise.
|
|
|
|
* node.c (recompute_blocks): New function, broken out of ...
(diskfs_cached_lookup): here. Now use call that.
(diskfs_set_translator): Likewise.
(create_symlink_hook): Likewise. Do nothing for zero-length target.
|
|
|
|
|
|
* file-statfs.c (diskfs_S_file_statfs): Zero out the struct statfs
before calling diskfs_set_statfs. Set f_namelen to diskfs_name_max
after the call.
* diskfs.h: Update comment.
|
|
|
|
* zero.c (zero_open): Check for END being null after strtoul call.
If character following number (*END) is b, multiply size by 512;
k or K, by 1024; m or M by 1024*1024; g or G by 1024*1024*1024.
|
|
|
|
* store.h (struct store_class): Fix typo in comment.
|
|
|
|
* copy.c (copy_read): When reading whole aligned pages, use vm_read.
Use MAP_FAILED in place of (void *) -1. Use memcpy in place of bcopy.
(copy_write): When reading whole aligned pages, use vm_write.
Use memcpy in place of bcopy.
|
|
|
|
* inode.c (write_node): Remove assert that dn_set_mtime et al are
clear. It is ok if they are set in parallel, because the latter
setting will be carried out eventually.
|
|
* main.c (pfinet_demuxer): New variable PI.
Store port info in PI, and dereference it if found.
|
|
|
|
* truncate.c (diskfs_truncate): Use & instead of %.
|
|
* inode.c (write_all_disknodes): Call diskfs_set_node_times after
pokel_sync, since it might delay a little.
(write_node): Remove assert that dn_set_mtime et al are clear.
It is ok if they are set in parallel, because the latter setting
will be carried out eventually.
|
|
* node-times.c (diskfs_set_node_times): Make individual flag checks
race-proof so we don't lose any flag settings.
|
|
* ops.c (op_readlink): Before returning, check if the buffer
pointed to by transp is ours. If not, munmap it.
(op_read): Likewise for bp.
(op_readdir): Don't alloca a buffer here. Instead initialize
BUF and BUFSIZE to 0 and let the server (eh, MiG) do it.
munmap BUF before returning.
|
|
* cache.c (scan_creds): Move I inside for-statement.
Replace inner for-loop with a while-loop. New variable
NEXT_I set to I->NEXT, because we might free I.
Set I to NEXT_I at end of while block.
Move update of leastidlastuse inside if block, because
otherwise we will constantly prevent ourself from scanning.
(scan_fhs): Very much the same.
(scan_replies): Likewise. Also free CR.
(check_cached_reply): Make HASH value absolute (as XID can be
negative, and thus the modulus).
Initialize REFERENCES to 1.
|
|
2000-11-30 Marcus Brinkmann <marcus@gnu.org>
* dir.c (diskfs_lookup_hard): If name is too long, clear
DS before returning ENAMETOOLONG.
pfinet:
2000-11-02 Marcus Brinkmann <marcus@gnu.org>
* tunnel.c (trivfs_S_io_get_owner): Add return type to silence
compiler warning.
|
|
|
|
* changelog: Update to reflect Debian upgrade.
* rc: New file.
* rules: Install rc.
* control: Add Build-Depends.
|
|
The last two changes introduced two new inode overlaps
(file_start was not shifted by store block size, and directories'
shifted file_start offset can be the same as the struct dirrect
offset of their first directory entry).
* inode.c (use_file_start_as_id): New function to determine
if to use file_start or struct dirrect * as node id.
The directory recognition code comes from read_disknode.
(cache_inode): Use use_file_start_as_id instead doing the work
ourselve. Shift file_start by store->log2_block_size.
(load_inode): Likewise.
* lookup.c (diskfs_get_directs): Likewise.
Declare use_file_start_id.
|
|
* ops.c (netfs_attempt_mkdir): Add casts -1 -> (struct iouser *) -1
to silence gcc warning.
(netfs_attempt_create_file): Likewise.
|
|
Fix hard link handling for non-zero length files.
* inode.c: Fix comment about inode numbers.
(node_cache): New member ID to store unique identifier.
(inode_cache_find): Change RECORD arg into ID and compare it
with id member of node_cache.
(cache_inode): Swap order of args and add new arg RR (change dr
into record along the way). Use RR to find out cache ID.
Use id member of node_cache to look for ID. Cache ID.
(load_inode): Call inode_cache_find with correct ID, depending
on RR and file size. Frob arguments to cache_inode to comply with
the new definition.
(read_disknode): Set st_ino according depending on RR and file size.
* lookup.c: Doc spelling fix.
(diskfs_get_directs): Include code again that was removed by last change,
but use it only if not symlink or zero length file.
|
|
Closes Debian Bug #68417:
* rr.c (rrip_work): In helper function add_comp set targused to
zero after malloc, and loop over realloc in case doubling is not
enough. After finalizing the link, set VALID_SL valid flag.
* inode.c (read_disknode): For links use rl->target instead
rl->name.
Closes Debian Bug #69281: Don't use file_start as inode numbers,
but the offset of the directory record in disk_image. This is what
Linux 2.4 does.
* isofs.h (struct disknode): New member struct dirrect *dr.
* inode.c: Fix comment about inode numbers.
(struct node_cache): Fix comment about file_start (it's not unique).
In fact, file_start is invalid for symlinks, and only stored here
for convenience. Maybe caching file_start can be avoided by
rearranging the code.
(inode_cache_find): Change first argument from off_t file_start
to struct dirrect *dr and fix the doc.
Compare cached value of DR with this argument, instead FILE_START.
(diskfs_cached_lookup): Set DR member of DN.
(load_inode): Call inode_cache_find with RECORD instead FILE_START.
Set DR member of DN.
(read_disknode): Set inode number to DR - DISK_IMAGE instead
FILE_START.
* lookup.c (diskfs_get_directs): Remove variable file_start.
Don't calculate file_start. Set D_FILENO to EP - DISK_IMAGE
instead FILE_START.
|
|
* hurd_types.h: Doc fix reported by Neal H Walfield
(neal@cs.uml.edu), STORAGE_NULL is actually STORAGE_ZERO.
|
|
* wire.c: Include <error.h>.
|
|
|
|
* wire.c (map_extent): Pass second arg of RTLD_NOLOAD to dlopen.
(RTLD_NOLOAD): Define macro to zero if undefined.
|
|
|
|
* wire.c (map_extent): Rewrite using dlsym on library's _end symbol.
|
|
* devprobe.c (main): Call device_close before freeing the device
port.
|
|
* Makefile (SRCS): Add tunnel.c
* tunnel.c: New file.
* linux-src/net/ipv4/devinet.c (configure_device): New argument PEER.
Implement support for setting the destination address for
point-to-point interfaces.
(inquire_device): New argument PEER.
Implement support to get the destination address.
* main.c: Include fcntl.h.
Update prototype of configure_device.
Set trivfs_support_read and trivfs_support_write to 1, as we support
those in some cases now. For the same reason, set trivfs_allow_open
to O_READ | O_WRITE.
(pfinet_demuxer): If the port is not in the socketport_class,
don't try io_server (so requests for trivfs are not catched too early).
(find_device): Use setup_tunnel_device for tun* interfaces.
(main): Add peer argument to configure_device call for the lo interface.
* options.c: Update prototypes for configure_device, inquire_device.
(options): Add --peer option.
(stuct parse_interface): Add peer member.
(parse_hook_add_interface): Initialize peer.
(parse_opt): Add a case for --peer.
Add peer argument to configure_device call.
(add_dev_opts): Add peer variable, add it to inquire_device call arguments.
Check for peer argument and add it to command line if it is there.
* pfinet.h: Add prototype for setup_tunnel_device.
|
|
* Makefile (SRCS): Add dummy.c
* dummy.c: New file.
* ethernet.c: Moved ETHER_PORT, READPT, READPTNAME to ...
(struct ether_device): ... here. New struct. ETHER_DEV is now a
pointer to a struct ether_device.
(ethernet_demuxer): New variables edev, dev. Iterate over linked
list ETHER_DEV to find correct readptname. Use dev instead
ETHER_DEV for socket buffer manipulation.
(ethernet_open): New variable edev. Use dev->priv to find correct
edev. Use members of edev instead global variables.
(ethernet_xmit): New variable edev. Use dev->priv to find correct
edev.Use member of edev instead global variable ETHER_PORT.
(setup_ethernet_device): New output argument DEVICE. New
variables edev and dev. Allocate memory for edev, add it to the
head of ETHER_DEV. Use dev instead ETHER_DEV. Use members of edev
instead global variables.
* main.c: ALREADY_OPEN removed.
(find_device): Fix comment. Redone to work with multiple devices
by iterating over DEV_BASE.
(enumerate_device): Likewise.
* pfinet.h: Add new argument to prototype of
setup_ethernet_device. Add prototype for setup_dummy_device.
Remove prototype for ETHER_DEV. Add prototype for DEV_BASE.
|
|
|