A valve for relieving a gaseous pressure of a branching unit being in flow communication with lungs of a subject is disclosed herein. The valve includes an inlet port (101) in flow communication with the branching unit and an outlet port (102) for discharging a gas flow from the inlet port to release the pressure. The valve also includes a valve seat (103) in flow communication with the inlet port, a valve member (104) which is forced against the valve seat to close a gas discharge and which member can be detached from the valve seat to facilitate gas discharge and a closing spring (105) for directing a predetermined closing force to the valve member (104). The valve also includes an actuator (107) being able to increase and decrease the closing force to the valve member. A corresponding method and arrangement for ventilating lungs of a subject is also provided. (FIG. 2)