Lahiru - Link below is a great article covering this topic. Note that using a spouse's hours can help you meet the material participation requirements. However, as the owner you still need to spend more than 50% of personal services and more than 750 hours on the real estate business on your own.
Alternatively, short-term rentals are generally treated as active business income and therefore are eligible to offset w-2 income.
Navigating the Real Estate Professional Rules
"When measuring material participation, a married taxpayer is required to count any hours performed by his or her spouse, even if the spouse does not own an interest in the business or if no joint return is filed.32 While this rule is advantageous because it makes it more likely the taxpayer materially participates in the real property trade or business, it is a trap for the unwary in the real estate professional context, as discussed below in Step 3."
"Step 3: Total the Hours From Real Property Trades or Businesses in Which the Taxpayer Materially Participates
Next, the taxpayer totals the hours spent in those real property trades or businesses in which the taxpayer materially participates. The statute makes clear, however, that while a married taxpayer includes the hours of his or her spouse in determining whether the taxpayer materially participates in a real property trade or business, the taxpayer must pass the two quantitative tests of Sec. 469(c)(7)(B) using only his or her own hours.35"