I am using Airlink Fully compatible Wireless N 150 Ultra Mini-USB Adapter (AWLL5099) with my RaspPi to get internet. I am also bridging this WiFi connection with an Ethernet cable to provide internet to my XBox 360.However, the WiFi drops out every 30-45 minutes. I am unsure why this is happening. The following is my /etc/network/interfaces setup:auto loiface lo inet loopbackauto wlan0iface wlan0 inet dhcpauto eth0iface eth0 inet dhcpauto br0iface br0 inet dhcpbridge_ports wlan0 eth0EDIT:Using hatesnakeslovepython's answer works! My connection no longer drops. I was using bridge_utils previously which is what introduced my problem. Exactly what the problem is I am not sure, but using the iptables setup fixed it.
RaspberryPi drops Wifi connection
networking;wifi;raspberry pi;bridge
I've also been trying to use my Pi as a wireless adapter for my Xbox 360. Initially, I had an issue where plugging in the ethernet cable (to the powered on Xbox) dropped the wifi connection, and the only way to get it to work again was to unplug and replug the USB wifi dongle (uses the smsc95xx driver, but I had the same issue with other dongles I tested).For reference, I'm using a similar configuration as posted at linuxquestions.org.Specifically, I used the following commands:sudo sysctl -w net.ipv4.ip_forward=1sudo ifconfig eth0 192.168.1.1sudo iptables -t nat -A POSTROUTING -o wlan0 -s 192.168.1.0/24 -j MASQUERADEThen, I configured the Xbox's network settings as IP address:  192.168.1.2Subnet mask: 255.255.255.0Gateway:     192.168.1.1and I set the primary DNS server to my router's IP address.This worked but, as I said, you had to replug the USB wifi adapter.What seems to have fixed (just tried this today) it is advice taken from the Raspberry Pi forum which cites the ifplugd daemon as the cause.Running the commands:sudo ifplugd eth0 --killsudo ifplugd eth0 --check-runningbefore setting up iptables seem to have fixed the problem for me.EDIT: To be clear, I now have the ifplugd kill command (ifplugd check-running just confirms that the daemon has been stopped) followed by the other three commands (sysctl, ifconfig, iptables) in my Pi's /etc/rc.local and the ethernet connection works correctly on startup.This might not be your issue, especially if it works for a few minutes before dropping. If not, the Pi is a little temperamental with USB hardware; you could always try another dongle (e.g. adapters with various Ralink chipsets seem quite popular for the Pi, and are cheap on eBay) or try a powered USB hub if you're not already using one.EDIT 2: If you actually do find you need to use the Ethernet connection for some reason (I was diagnosing problems with wifi), an easy way of doing this is something like sudo route add default gw 192.168.0.1 (replacing 192.168.0.1 with your router's IP).