Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 04a3d311 authored by Marc Zyngier's avatar Marc Zyngier Committed by Linus Torvalds
Browse files

[PATCH] Fix Specialix SI probing



As the (probably) last user of a Specialix SI board, I noticed that
recent kernels would fail to probe the sucker.  Quick investigation
indicate a few missing braces...

I left the double probing in place, as it looks like it's been here
forever.

Signed-off-by: default avatarMarc Zyngier <maz@misterjones.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 48970800
Loading
Loading
Loading
Loading
+8 −4
Original line number Original line Diff line number Diff line
@@ -2173,16 +2173,18 @@ static int probe_si (struct sx_board *board)
	if ( IS_SI1_BOARD(board)) {
	if ( IS_SI1_BOARD(board)) {
		/* This should be an SI1 board, which has this
		/* This should be an SI1 board, which has this
		   location writable... */
		   location writable... */
		if (read_sx_byte (board, SI2_ISA_ID_BASE) != 0x10)
		if (read_sx_byte (board, SI2_ISA_ID_BASE) != 0x10) {
			func_exit ();
			func_exit ();
			return 0; 
			return 0; 
		}
	} else {
	} else {
		/* This should be an SI2 board, which has the bottom
		/* This should be an SI2 board, which has the bottom
		   3 bits non-writable... */
		   3 bits non-writable... */
		if (read_sx_byte (board, SI2_ISA_ID_BASE) == 0x10)
		if (read_sx_byte (board, SI2_ISA_ID_BASE) == 0x10) {
			func_exit ();
			func_exit ();
			return 0; 
			return 0; 
		}
		}
	}


	/* Now we're pretty much convinced that there is an SI board here, 
	/* Now we're pretty much convinced that there is an SI board here, 
	   but to prevent trouble, we'd better double check that we don't
	   but to prevent trouble, we'd better double check that we don't
@@ -2192,16 +2194,18 @@ static int probe_si (struct sx_board *board)
	if ( IS_SI1_BOARD(board)) {
	if ( IS_SI1_BOARD(board)) {
		/* This should be an SI1 board, which has this
		/* This should be an SI1 board, which has this
		   location writable... */
		   location writable... */
		if (read_sx_byte (board, SI2_ISA_ID_BASE) != 0x10)
		if (read_sx_byte (board, SI2_ISA_ID_BASE) != 0x10) {
			func_exit();
			func_exit();
			return 0; 
			return 0; 
		}
	} else {
	} else {
		/* This should be an SI2 board, which has the bottom
		/* This should be an SI2 board, which has the bottom
		   3 bits non-writable... */
		   3 bits non-writable... */
		if (read_sx_byte (board, SI2_ISA_ID_BASE) == 0x10)
		if (read_sx_byte (board, SI2_ISA_ID_BASE) == 0x10) {
			func_exit ();
			func_exit ();
			return 0; 
			return 0; 
		}
		}
	}


	printheader ();
	printheader ();