#include <bits/stdc++.h>
using namespace std;
void fast() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
}
int main() {
  fast();
  long long t, n, i, j, k, x, y, c;
  long long m;
  cin >> n >> m;
  vector<long long> a(n), b(m);
  for (long long i = 0; i < n; i += 1) cin >> a[i];
  ;
  for (long long i = 0; i < m; i += 1) cin >> b[i];
  ;
  long long minn = *max_element(a.begin(), a.end());
  long long maxx = *min_element(b.begin(), b.end());
  if (minn > maxx) {
    cout << -1;
    return 0;
  }
  long long ans = 0;
  for (long long i = 0; i < n; i += 1) {
    ans += (a[i] * m);
  }
  sort(a.rbegin(), a.rend());
  sort(b.rbegin(), b.rend());
  k = 0;
  long long cnt[n];
  i = 0;
  c = 0;
  j = 0;
  memset(cnt, (0), sizeof(cnt));
  while (c < m && j < m) {
    bool flag = false;
    if (b[j] >= a[i]) {
      if (b[j] > a[i]) {
        if (cnt[i] < m - 1) {
          cnt[i]++;
          ans += abs(b[j] - a[i]);
          ++c;
          ++j;
          flag = true;
        }
      } else {
        ans += abs(b[j] - a[i]);
        ++c;
        ++j;
        flag = true;
      }
    }
    if (!flag) {
      ++i;
    }
  }
  cout << ans;
}
