Consider the following example. The requirements for line style and placement among the two y axises are in the comments.
Fs1 = 5;
Fs2 = 25;
t1 = (0:1:19)/Fs1;
t2 = (0:1:19)/Fs2;
fc = 5;
y11 = sin(2*pi*fc*t1); % In left y axis with style 'o' | legend entry - 'raw signal'
y12 = 2*sin(2*pi*fc*t2); % In left y axis with style '--' | legend entry - 'upsampled signal'
y21 = 5; % In right y axis with style ':' | legend entry - 'DC'