If your PC has green (front), orange (center & sub), and black (rear surround) audio outputs then those should connect to the multi-channel input on the receiver. Set the PC to 5.1 The PC is doing the surround processing.
If you PC has digital audio output then connect that to a digital input on the receiver. Select that as the audio device on the PC. Your receiver is doing the processing.
You need to assign the connection you use on the receiver to an input as per the manual. https/usa.yamaha.com/files/download/other_assets/2/319822/01_om_htr-5940.pdf
I found a solution which I connected my 3.5 mm into back of my PC (green) to RCA in "CD" on the back of the receiver and set "CD" where I realized that my PC audio configuration (Realtek audio) was set "digital" which supposed to be set to "Speakers/Headphones".