Whenever Binary Semaphores are used to synchronize the Critical Section by a Binary Semaphore Variable lets take it "S".Generally the code structure will be like below
P(s) // Entry Section
Critical Section
V(s) // Exit Section
we do down operation to achieve mutual exclusion i.e once a process its entered into the critical section and executing it, meanwhile no other process is allowed to execute the critical section and more on it will be suspended and it's PCB will be kept into the suspended list of semaphore variable i.e. S.
After execution of critical section the process will perform up operation on S inside exit section and binary semaphore does not always make S value to 1. It makes the S.value = 1 once the S.list is empty and it will simply wake up a process from the S.list and allocate the critical section to it when S.list is not empty.
Now your confusion is, "Why UP() operation is not performing S.value = 1 when S.list is not empty ?"
Lets do it first, once we will make S.value =1 when S.list is not empty. There will be chance of process P2 may enter into starvation.Because once the S.value is 1 any process can come and perform down operation and execute critical section. This the process P2 may not get chance to execute the critical section.