Commit Graph

145274 Commits

Author SHA1 Message Date
avg
66df72ab44 udf_read: correctly read data from files with data embedded into fentry,
... as opposed to files with data in extents.
Some UDF authoring tools produce this type of file for sufficiently small
data files.

Approved by: jhb (mentor)
2009-02-26 12:33:12 +00:00
avg
3f68170c35 udf_strategy: tiny optimization of logic, calculations; extra diagnostics
Use bit-shift instead of division/multiplication.
Act on error as soon as it is detected.
Report attempt to read data embedded in file entry via regular way.
While there, fix lblktosize macro and make use of it.

No functionality should change as a result.

Approved by: jhb (mentor)
2009-02-26 12:33:02 +00:00
ed
280ef3dd23 Remove redundant assignment of `p'.
`p' is already initialized with `td->td_proc'. Because td is always
curthread, it is safe to initialize it without any locks.

Found by:	LLVM's scan-build
2009-02-26 12:12:34 +00:00
ed
0f8dee0434 Remove redundant assignment of `s'.
The variable is already initialized to `nptr'.

Found by:	LLVM's scan-build
2009-02-26 12:06:46 +00:00
ed
49be8ddba0 Remove unneeded variable assignment.
The ts variable is always initialized a few lines below.

Found by:	LLVM scan-build
2009-02-26 12:02:38 +00:00
rwatson
bf80a0a378 Add static tracing for privilege checking:
priv:kernel:priv_check:priv_ok fires for granted privileges
  priv:kernel:priv_check:priv_errr fires for denied privileges

The first argument is the requested privilege number.  The naming
convention is a little different from the OpenSolaris equivilent
because we can't have '-' in probefunc names, and our privilege
namespace is different.

MFC after:	1 week
2009-02-26 10:56:13 +00:00
ed
226255f0b6 Silence compiler warning inside our ^T handler.
It turns out we're casting fixpt_t* to int*.

Spotted by:	clang
2009-02-26 10:38:19 +00:00
ed
516ad9be6d Use unsigned longs for the TTY's sysctl stats.
Spotted by:	clang
2009-02-26 10:28:32 +00:00
ed
1c7d1f084a Don't use PTY name as format string, even though it isn't insecure here.
It's guaranteed that the `name' variable always contains a string of the
form pty[l‐sL‐S][0‐9a‐v], but I'd rather keep the compiler happy (LLVM).
2009-02-26 10:14:10 +00:00
sam
53dcaae80d add more gpio registers 2009-02-26 06:16:15 +00:00
sobomax
1b8152b75c Fix typo in comments in r189023. 2009-02-25 22:24:56 +00:00
jkim
c7f643835f Enable support for PAT_WRITE_PROTECTED and PAT_UNCACHED cache modes
unconditionally on amd64.  On i386, we assume PAT is usable if the CPU
vendor is not Intel or CPU model is newer than Pentium IV.

Reviewed by:	alc, jhb
2009-02-25 20:26:48 +00:00
rnoland
35f0e5ba8f The GM45 handles vblank differently. Pull the changes from Intel in.
MFC after:	2 Weeks
2009-02-25 20:24:13 +00:00
rnoland
4abf3eb200 Remove D_NEEDGIANT.
MFC after:	2 weeks
2009-02-25 18:56:49 +00:00
rnoland
6a02e32ede Turn on MSI if the card supports it. There is a blacklist for chips
which report that they are capable of MSI, but don't work correctly.

MFC after:	2 weeks
2009-02-25 18:54:35 +00:00
rnoland
ede7b46946 Prepare the radeon driver for MSI support.
MFC after:	2 weeks
2009-02-25 18:50:35 +00:00
rnoland
8df73af328 Add some vblank related debugging and replace the DRM_WAIT_ON macro
with a localized version.

MFC after:	2 weeks
2009-02-25 18:48:33 +00:00
rnoland
ca01a44d40 This was part of a sync to the code that Intel is shipping in linux.
- Remove the old TTM interface
	- Move register definitions to i915_reg.h
	- Overhaul the irq handler

MFC after:	2 weeks
2009-02-25 18:44:50 +00:00
rnoland
12840cf005 The i915 driver was the only consumer of locked task support.
Now that it doesn't use it anymore, get right of the taskqueue
and locked task support.

MFC after:	2 weeks
2009-02-25 18:25:47 +00:00
rnoland
577eb25e17 The vblank_swap ioctl was fundamentally race prone. Get rid of it.
MFC after:	2 weeks
2009-02-25 18:22:57 +00:00
rnoland
69ae0a399c There is no reason to hold the lock here.
When I was LOCK_PROFILING this was pretty high up and there is no
reason for it.

MFC after:	2 weeks
2009-02-25 18:19:16 +00:00
rnoland
1e7c6ababe Remove the PZERO priority from mtx_sleep.
MFC after:	2 weeks
2009-02-25 18:16:50 +00:00
alc
8a8f5251fa Prior to r188331 a map entry's last read offset was only updated by a hard
fault.  In r188331 this update was relocated because of synchronization
changes to a place where it would occur on both hard and soft faults.  This
change again restricts the update to hard faults.
2009-02-25 07:52:53 +00:00
sobomax
ba8a8daf8d Make machdep.hyperthreading_enabled tunable working with the SCHED_ULE.
Unlike with SCHED_BSD, however, it can only be set to 0 at boot time,
it's not possible to change it at runtime.

Reviewed by:	jhb
MFC after:	1 month
2009-02-25 01:49:01 +00:00
yongari
37601fa768 Update to latest 3Com firmware image. The latest fimware is
required to make 3CR990 familiy controllers run on NV flash
firmware version 03.001.008.
The latest firmware added HMAC digest information so teach txp(4)
to pass them to sleep image before downloading is started.

While I'm here restore previous IMR/IER register if firmware
downloading have failed.

PR:	kern/89876, kern/132047
2009-02-25 01:12:56 +00:00
thompsa
fc03dc2730 Update paths for ehci_ixp4xx.c in the old and new stacks. 2009-02-24 23:34:02 +00:00
thompsa
eb7404d4aa Fix path and config name for ehci_mbus.c 2009-02-24 23:30:52 +00:00
thompsa
d6d9119787 These are no longer needed. 2009-02-24 23:27:59 +00:00
jhb
c9807908ae Fix some more issues with the real mode BTX.
The old BTX passed the general purpose registers from the 32-bit client to
the routines called via virtual 86 mode.  The new BTX did the same thing.
However, it turns out that some instructions behave differently in virtual 86
mode and real mode (even though this is under-documented).  For example, the
LEAVE instruction will cause an exception in real mode if any of the upper
16-bits of %ebp are non-zero after it executes.  In virtual 8086 mode the
upper 16-bits are simply ignored.  This could cause faults in hardware
interrupt handlers that inherited an %ebp larger than 0xffff from the 32-bit
client (loader, boot2, etc.) while running in real mode.

To fix, when executing hardware interrupt handlers provide an explicit clean
state where all the general purpose and segment registers are zero upon
entry to the interrupt handler.  While here, I attempted to simplify the
control flow in the 'intusr' code that sets up the various stack frames
and exits protected mode to invoke the requested routine via real mode.

A huge thanks to Tor Egge (tegge@) for debugging this issue.

Submitted by:	tegge
Reviewed by:	tegge
Tested by:	bz
MFC after:	1 week
2009-02-24 23:11:15 +00:00
kib
66c697aade Revert the addition of the freelist argument for the vm_map_delete()
function, done in r188334. Instead, collect the entries that shall be
freed, in the deferred_freelist member of the map. Automatically purge
the deferred freelist when map is unlocked.

Tested by:	pho
Reviewed by:	alc
2009-02-24 20:57:43 +00:00
kib
47de55da04 Add the assertion macros for the map locks. Use them in several map
manipulation functions.

Tested by:	pho
Reviewed by:	alc
2009-02-24 20:43:29 +00:00
kib
eb4f9da70c Use vm_map_entry_t instead of explicit struct vm_map_entry *.
Reviewed by:	alc
2009-02-24 20:27:48 +00:00
kib
8ee2717f0a Update the comment after the r188334.
Reviewed by:	alc
2009-02-24 20:23:16 +00:00
rdivacky
e5bfcba080 Change the functions to ANSI in those cases where it breaks promotion
to int rule. See ISO C Standard: SS6.7.5.3:15.

Approved by:	kib (mentor)
Reviewed by:	warner
Tested by:	silence on -current
2009-02-24 18:09:31 +00:00
thompsa
edb8ebb3d4 This copy of usbdevs is unused. 2009-02-24 17:26:37 +00:00
ed
7db4b282f9 Also use proper capitalisation of FreeBSD in other source files.
Approved by:	thompsa
2009-02-24 17:15:29 +00:00
ed
fdc352cfaf Use my address of the FreeBSD project in the copyright statement in USB2.
If I remember correctly, our policy was to use FreeBSD with proper
capitalisation in our email addresses. Fix this in Nick Hibma's address
as well.
2009-02-24 17:10:43 +00:00
thompsa
2c58eacc70 delete-old does not recursively delete dirs so list all its contents too.
Spotted by:	naddy
2009-02-24 16:47:59 +00:00
ru
ae7b564b50 With only one threading library, simplify the logic of setting SHLIBDIR. 2009-02-24 16:23:34 +00:00
ru
9d424734ae Restore the install location of libssp.so.0.
Noticed by:	tegge
2009-02-24 16:14:15 +00:00
jhb
ccc9172c8d Bring back the code to prime the ACCESS cache when fetching attributes for
an NFS file.  Now the priming is conditional on  a new
vfs.nfs.prime_access_cache sysctl.  For now I've left the default setting
to disabling the priming.

Requested by:	 scottl
2009-02-24 16:01:56 +00:00
sam
f621884a68 fix typo's 2009-02-24 15:43:42 +00:00
rwatson
313ce0df5b In tcp_usr_shutdown() and tcp_usr_send(), I missed converting NULL
checks for the tcpcb, previously used to detect complete disconnection,
with INP_DROPPED checks.  Correct that, preventing shutdown() from
improperly generating a TCP segment with destination IP and port of
0.0.0.0:0.

PR:		kern/132050
Reported by:	david gueluy <david.gueluy at netasq.com>
MFC after:	3 weeks
2009-02-24 11:17:50 +00:00
thompsa
729961165c MFp4 //depot/projects/usb@158015
Add support for the Sael M460 3G modem.

Submitted by:	Hans Petter Selasky
2009-02-24 05:35:48 +00:00
thompsa
ba3aaad96e Fix compiler warning. 2009-02-24 04:16:19 +00:00
thompsa
f1a1841fd4 MFp4 //depot/projects/usb@157974
Add support for setting and getting the USB template value through libusb20 and
usbconfig.

Submitted by:	Hans Petter Selasky
2009-02-24 03:43:05 +00:00
thompsa
8041f6f694 MFp4 //depot/projects/usb@157958
- We don't need to exit the Giant mutex when sleeping. This is done
  automatically. Replace Giant by NULL mutex for all control requests in the
  enumeration path.
- Optimise away duplicate alternate interface selection requests in USB Host
  mode.

Submitted by:	Hans Petter Selasky
2009-02-24 03:41:52 +00:00
thompsa
111921b05d MFp4 //depot/projects/usb@157909
Changes to make implementing USB NDIS easier.

Submitted by:	Hans Petter Selasky
2009-02-24 03:40:48 +00:00
thompsa
b169f30295 MFp4 //depot/projects/usb@157855
Document short_frames_ok.

Submitted by:	Hans Petter Selasky
2009-02-24 03:40:09 +00:00
thompsa
52d3d977f2 MFp4 //depot/projects/usb@157853
Clean up old way of polling the USB hardware.  The existing polling support was
a bit hackish.

Submitted by:	Hans Petter Selasky
2009-02-24 03:39:13 +00:00