Deleted Added
full compact
freebsd32_misc.c (220238) freebsd32_misc.c (220791)
1/*-
2 * Copyright (c) 2002 Doug Rabson
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 11 unchanged lines hidden (view full) ---

20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 */
26
27#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2002 Doug Rabson
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 11 unchanged lines hidden (view full) ---

20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 */
26
27#include <sys/cdefs.h>
28__FBSDID("$FreeBSD: head/sys/compat/freebsd32/freebsd32_misc.c 220238 2011-04-01 11:16:29Z kib $");
28__FBSDID("$FreeBSD: head/sys/compat/freebsd32/freebsd32_misc.c 220791 2011-04-18 16:32:22Z mdf $");
29
30#include "opt_compat.h"
31#include "opt_inet.h"
32#include "opt_inet6.h"
33
34#define __ELF_WORD_SIZE 32
35
36#include <sys/param.h>

--- 2748 unchanged lines hidden (view full) ---

2785 bcopy(&stat.name[0], &stat32.name[0], sizeof(stat.name));
2786 CP(stat, stat32, refs);
2787 CP(stat, stat32, id);
2788 PTROUT_CP(stat, stat32, address);
2789 CP(stat, stat32, size);
2790 bcopy(&stat.pathname[0], &stat32.pathname[0], sizeof(stat.pathname));
2791 return (copyout(&stat32, uap->stat, version));
2792}
29
30#include "opt_compat.h"
31#include "opt_inet.h"
32#include "opt_inet6.h"
33
34#define __ELF_WORD_SIZE 32
35
36#include <sys/param.h>

--- 2748 unchanged lines hidden (view full) ---

2785 bcopy(&stat.name[0], &stat32.name[0], sizeof(stat.name));
2786 CP(stat, stat32, refs);
2787 CP(stat, stat32, id);
2788 PTROUT_CP(stat, stat32, address);
2789 CP(stat, stat32, size);
2790 bcopy(&stat.pathname[0], &stat32.pathname[0], sizeof(stat.pathname));
2791 return (copyout(&stat32, uap->stat, version));
2792}
2793
2794int
2795freebsd32_posix_fallocate(struct thread *td,
2796 struct freebsd32_posix_fallocate_args *uap)
2797{
2798 struct posix_fallocate_args ap;
2799
2800 ap.fd = uap->fd;
2801 ap.offset = (uap->offsetlo | ((off_t)uap->offsethi << 32));
2802 ap.len = (uap->lenlo | ((off_t)uap->lenhi << 32));
2803 return (posix_fallocate(td, &ap));
2804}