[NC10] Kernel 2.6.31

Discussions about Linux installation and configuration on Samsung laptops
User avatar
voRia
Administrator
Administrator
Posts: 1378
Joined: 12/02/2009, 18:08
Location: Italy
Contact:

Re: [NC10] Kernel 2.6.31

Postby voRia » 23/10/2009, 23:27

I'm uploading right now a new kernel with a patch applied which should fix your problem.
It will be available in the next few hours, the time to build it.
Let me know if it works.
Image
Please consider a little donation to keep the 'Linux On My Samsung' project up and running. Thank you!

JMFTheVCI
Newbie
Newbie
Posts: 13
Joined: 15/04/2009, 14:35

Re: [NC10] Kernel 2.6.31

Postby JMFTheVCI » 25/10/2009, 7:53

Hi voRia, your application of the fix was good. I am now able to use my 3g USB modem again. [To make this post.]

Sorry it took such a long time to test it. I tried to do a dual-boot with Karmic and the 9.10 installer partitioner crashed and hosed my Jaunty ext3 filesystem. It took about 18 hours for fsck to fix all the errors!

Back up and running. Thanks.

SometimesRomano
Newbie
Newbie
Posts: 1
Joined: 04/02/2011, 6:19

Re: RE: [NC10] Kernel 2.6.31

Postby SometimesRomano » 04/02/2011, 7:08

Hey all, brand new to the forum but came here looking for a way to fix the brightness issues on my Samsung N150 Plus.

The bash script posted by voRia wasn't working for me 'out of the box' so to speak. I have modified it slightly, my first time messing with bash scripts.

Code: Select all


#!/bin/sh


# adjust backlight via setpci and dpms via vbetool


# Check if root called this script
USER=`whoami`
if [ $USER != "root" ]; then
   echo "Need to be root to run this script."
   exit 1
fi

# Get old value
OLD2=`setpci -s 00:02.0 F4.B`

OLD=0x$OLD2

case "$1" in
   inc)
        # Check if value given for increase
      if [ -z "$2" ]; then
         echo "Usage: $0 $1 <value>"
         exit 1
      fi

      # Take second argument as value to increment
      NEW=$(( $OLD + $2 ))

      # Set new value
      $0 set $NEW
   ;;

   dec)
        # Check if value given for decrease
      if [ -z "$2" ]; then
         echo "Usage: $0 $1 <value>"
         exit 1
      fi
     
      # Take second argument as value to decrement
      NEW=$(( $OLD - $2 ))

      # Set new value
      $0 set $NEW
   ;;

   set)
      # Check if value given
      if [ -z "$2" ]; then
         echo "Usage: $0 $1 <value>"
         exit 1
      fi
     
      # Take second argument as value to set
      NEW=$2

      # Check if value less than 0
      if [ "$NEW" -lt "0" ]; then
         NEW=0
      fi

      # Check if value greater than 255
      if [ "$NEW" -gt "255" ]; then
         NEW=255
      fi
   
      # Set new value
      setpci -s 00:02.0 F4.B=`echo "obase=16; ibase=10; $NEW" | bc`
   ;;

   toggle)
      # Path to logfile
      LOG=/tmp/backlight.log

      # Check if logfile does not exist
           if [ ! -f $LOG ]; then
         vbetool dpms off
         touch $LOG
      else
         vbetool dpms on
         rm -rf $LOG
      fi
   ;;

   *)
      echo "Usage: $0 (inc <value>|dec <value>|set <value>|toggle)"
      echo "Current Value: $OLD2"
      exit 1
   ;;
esac

exit 0




Usage is for me:

Code: Select all

gksudo ./myscript.sh

I've added a line to the script to echo the current set value if you don't give parameters.
And:

Code: Select all

gksudo ./myscript.sh set XX
gksudo ./myscript.sh inc XX
gksudo ./myscript.sh dec XX

set value must be decimal from 0-255
inc value must be decimal from 0-255 (increase)
dec value must be decimal from 0-255 (decrease)

Be careful setting the value to 0 or decreasing the value to 0, as it turns off the display backlight completely.

I know I've kicked up something pretty old on this forum but I needed a fix, maybe other do to :)

Let me know if there are any issues/questions

and thanks to voRia for most of the hard work

-SometimesRomano
2.6.35-25-generic
Ubutnu 10.10
Samsung N150 Plus
250GB HD
1GB RAM


Return to “Linux On My Samsung”

Who is online

Users browsing this forum: No registered users and 2 guests