Add GHA to cancel redundant GHA workflows except on master (#54689)
Summary:
Relands https://github.com/pytorch/pytorch/issues/54685 with the fix to filter out master
Tested with samestep in other repository.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/54689
Reviewed By: walterddr
Differential Revision: D27330804
Pulled By: janeyx99
fbshipit-source-id: 06d8199af6173eedca2e7db4a1fd7b9a143d29d2